@sogni-ai/sogni-client 5.84.1 → 5.84.2
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/CHANGELOG.md +7 -0
- package/dist/Projects/index.js +8 -0
- package/dist/Projects/index.js.map +1 -1
- package/dist/Projects/utils/imageUploadBody.d.ts +14 -0
- package/dist/Projects/utils/imageUploadBody.js +88 -0
- package/dist/Projects/utils/imageUploadBody.js.map +1 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist-esm/Projects/index.js +8 -0
- package/dist-esm/Projects/index.js.map +1 -1
- package/dist-esm/Projects/utils/imageUploadBody.js +85 -0
- package/dist-esm/Projects/utils/imageUploadBody.js.map +1 -0
- package/dist-esm/version.js +1 -1
- package/package.json +2 -1
- package/src/Projects/index.ts +8 -0
- package/src/Projects/utils/imageUploadBody.ts +68 -0
- package/src/version.ts +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
## [5.84.2](https://github.com/Sogni-AI/sogni-client/compare/v5.84.1...v5.84.2) (2026-11-15)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **projects:** refuse text in place of image bytes before uploading an image slot ([3c0d411](https://github.com/Sogni-AI/sogni-client/commit/3c0d411a2f92567048450a346c94df6feb0f544f))
|
|
7
|
+
|
|
1
8
|
## [5.84.1](https://github.com/Sogni-AI/sogni-client/compare/v5.84.0...v5.84.1) (2026-11-15)
|
|
2
9
|
|
|
3
10
|
|
package/dist/Projects/index.js
CHANGED
|
@@ -64,6 +64,7 @@ const Cache_js_1 = __importDefault(require("../lib/Cache.js"));
|
|
|
64
64
|
const Job_js_1 = require("./Job.js");
|
|
65
65
|
const index_js_3 = require("./utils/index.js");
|
|
66
66
|
const fileContentType_js_1 = require("./utils/fileContentType.js");
|
|
67
|
+
const imageUploadBody_js_1 = require("./utils/imageUploadBody.js");
|
|
67
68
|
const imageLayers_js_1 = require("./utils/imageLayers.js");
|
|
68
69
|
const validation_js_1 = require("../lib/validation.js");
|
|
69
70
|
const ModelTiersRaw_js_1 = require("./types/ModelTiersRaw.js");
|
|
@@ -2793,6 +2794,7 @@ class ProjectsApi extends ApiGroup_js_1.default {
|
|
|
2793
2794
|
const imageId = (0, getUUID_js_1.default)();
|
|
2794
2795
|
const assertSession = (_a = this._preparingSessions.get(projectId)) !== null && _a !== void 0 ? _a : (0, requestSession_js_1.captureRequestSession)(this.client.auth);
|
|
2795
2796
|
assertSession();
|
|
2797
|
+
yield (0, imageUploadBody_js_1.assertImageUploadBody)(file, 'Guide image');
|
|
2796
2798
|
const contentType = (0, fileContentType_js_1.getFileContentType)(file);
|
|
2797
2799
|
if (yield this._bindSavedUpload(file, contentType, { projectId, type: 'startingImage' }))
|
|
2798
2800
|
return imageId;
|
|
@@ -2829,6 +2831,7 @@ class ProjectsApi extends ApiGroup_js_1.default {
|
|
|
2829
2831
|
const imageId = (0, getUUID_js_1.default)();
|
|
2830
2832
|
const assertSession = (_a = this._preparingSessions.get(projectId)) !== null && _a !== void 0 ? _a : (0, requestSession_js_1.captureRequestSession)(this.client.auth);
|
|
2831
2833
|
assertSession();
|
|
2834
|
+
yield (0, imageUploadBody_js_1.assertImageUploadBody)(file, 'ControlNet image');
|
|
2832
2835
|
const contentType = (0, fileContentType_js_1.getFileContentType)(file);
|
|
2833
2836
|
if (yield this._bindSavedUpload(file, contentType, { projectId, type: 'cnImage' }))
|
|
2834
2837
|
return imageId;
|
|
@@ -2866,6 +2869,7 @@ class ProjectsApi extends ApiGroup_js_1.default {
|
|
|
2866
2869
|
const imageIndex = (index + 1);
|
|
2867
2870
|
const assertSession = (_a = this._preparingSessions.get(projectId)) !== null && _a !== void 0 ? _a : (0, requestSession_js_1.captureRequestSession)(this.client.auth);
|
|
2868
2871
|
assertSession();
|
|
2872
|
+
yield (0, imageUploadBody_js_1.assertImageUploadBody)(file, `Context image ${imageIndex}`);
|
|
2869
2873
|
const contentType = (0, fileContentType_js_1.getFileContentType)(file);
|
|
2870
2874
|
if (yield this._bindSavedUpload(file, contentType, {
|
|
2871
2875
|
projectId,
|
|
@@ -2912,6 +2916,7 @@ class ProjectsApi extends ApiGroup_js_1.default {
|
|
|
2912
2916
|
const type = `keyframeImage${slot}`;
|
|
2913
2917
|
const assertSession = (_a = this._preparingSessions.get(projectId)) !== null && _a !== void 0 ? _a : (0, requestSession_js_1.captureRequestSession)(this.client.auth);
|
|
2914
2918
|
assertSession();
|
|
2919
|
+
yield (0, imageUploadBody_js_1.assertImageUploadBody)(file, `Keyframe image ${slot}`);
|
|
2915
2920
|
const contentType = (0, fileContentType_js_1.getFileContentType)(file);
|
|
2916
2921
|
if (yield this._bindSavedUpload(file, contentType, { projectId, type }))
|
|
2917
2922
|
return imageId;
|
|
@@ -2950,6 +2955,7 @@ class ProjectsApi extends ApiGroup_js_1.default {
|
|
|
2950
2955
|
const imageId = (0, getUUID_js_1.default)();
|
|
2951
2956
|
const assertSession = (_a = this._preparingSessions.get(projectId)) !== null && _a !== void 0 ? _a : (0, requestSession_js_1.captureRequestSession)(this.client.auth);
|
|
2952
2957
|
assertSession();
|
|
2958
|
+
yield (0, imageUploadBody_js_1.assertImageUploadBody)(file, 'Reference image');
|
|
2953
2959
|
const contentType = (0, fileContentType_js_1.getFileContentType)(file);
|
|
2954
2960
|
if (yield this._bindSavedUpload(file, contentType, { projectId, type: 'referenceImage' }))
|
|
2955
2961
|
return imageId;
|
|
@@ -2990,6 +2996,7 @@ class ProjectsApi extends ApiGroup_js_1.default {
|
|
|
2990
2996
|
const imageId = (0, getUUID_js_1.default)();
|
|
2991
2997
|
const assertSession = (_a = this._preparingSessions.get(projectId)) !== null && _a !== void 0 ? _a : (0, requestSession_js_1.captureRequestSession)(this.client.auth);
|
|
2992
2998
|
assertSession();
|
|
2999
|
+
yield (0, imageUploadBody_js_1.assertImageUploadBody)(file, 'Reference mask');
|
|
2993
3000
|
const contentType = (0, fileContentType_js_1.getFileContentType)(file);
|
|
2994
3001
|
if (yield this._bindSavedUpload(file, contentType, { projectId, type: 'referenceMask' }))
|
|
2995
3002
|
return imageId;
|
|
@@ -3030,6 +3037,7 @@ class ProjectsApi extends ApiGroup_js_1.default {
|
|
|
3030
3037
|
const imageId = (0, getUUID_js_1.default)();
|
|
3031
3038
|
const assertSession = (_a = this._preparingSessions.get(projectId)) !== null && _a !== void 0 ? _a : (0, requestSession_js_1.captureRequestSession)(this.client.auth);
|
|
3032
3039
|
assertSession();
|
|
3040
|
+
yield (0, imageUploadBody_js_1.assertImageUploadBody)(file, 'End reference image');
|
|
3033
3041
|
const contentType = (0, fileContentType_js_1.getFileContentType)(file);
|
|
3034
3042
|
if (yield this._bindSavedUpload(file, contentType, { projectId, type: 'referenceImageEnd' }))
|
|
3035
3043
|
return imageId;
|