@civitai/client 0.2.0-beta.21 → 0.2.0-beta.23
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/generated/schemas.gen.d.ts +2083 -2028
- package/dist/generated/schemas.gen.js +2093 -2031
- package/dist/generated/services.gen.d.ts +88 -90
- package/dist/generated/services.gen.js +100 -147
- package/dist/generated/types.gen.d.ts +25 -9
- package/dist/generated/types.gen.js +5 -0
- package/dist/utils/types.d.ts +3 -0
- package/dist/utils/types.js +1 -0
- package/package.json +2 -2
|
@@ -1,309 +1,262 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
// This file is auto-generated by @hey-api/openapi-ts
|
|
3
|
-
|
|
4
|
-
exports.patchWorkflowStep = exports.updateWorkflowStep = exports.getWorkflowStep = exports.removeWorkflowTag = exports.removeAllWorkflowTags = exports.addWorkflowTag = exports.deleteWorkflow = exports.patchWorkflow = exports.updateWorkflow = exports.getWorkflow = exports.queryWorkflows = exports.submitWorkflow = exports.patchWorkerResources = exports.updateWorkerRegistration = exports.getRegistration = exports.deleteWorker = exports.getWorker = exports.queryWorkers = exports.createWorker = exports.downloadResource = exports.getJobs = exports.invalidateResource = exports.getResource = exports.deleteConfiguration = exports.getConfiguration = exports.queryConfigurations = exports.createConfiguration = exports.getBlob = exports.putV2ProvidersBlobsByBlobKey = void 0;
|
|
5
|
-
const client_fetch_1 = require("@hey-api/client-fetch");
|
|
6
|
-
const putV2ProvidersBlobsByBlobKey = (options) => {
|
|
7
|
-
var _a;
|
|
8
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client_fetch_1.client).put({
|
|
9
|
-
...options,
|
|
10
|
-
url: '/v2/providers/blobs/{blobKey}',
|
|
11
|
-
});
|
|
12
|
-
};
|
|
13
|
-
exports.putV2ProvidersBlobsByBlobKey = putV2ProvidersBlobsByBlobKey;
|
|
2
|
+
import { client } from '@hey-api/client-fetch';
|
|
14
3
|
/**
|
|
15
|
-
* Get blob by ID.
|
|
4
|
+
* Get blob by ID. This will return the blob as a binary stream.
|
|
16
5
|
*/
|
|
17
|
-
const getBlob = (options) => {
|
|
6
|
+
export const getBlob = (options) => {
|
|
18
7
|
var _a;
|
|
19
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
8
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).get({
|
|
20
9
|
...options,
|
|
21
10
|
url: '/v2/consumer/blobs/{blobId}',
|
|
22
11
|
});
|
|
23
12
|
};
|
|
24
|
-
exports.getBlob = getBlob;
|
|
25
13
|
/**
|
|
26
|
-
*
|
|
14
|
+
* Handles HTTP HEAD requests for a specific blob, checking its existence and NSFW level.
|
|
27
15
|
*/
|
|
28
|
-
const
|
|
16
|
+
export const headBlob = (options) => {
|
|
29
17
|
var _a;
|
|
30
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
18
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).head({
|
|
31
19
|
...options,
|
|
32
|
-
url: '/v2/
|
|
20
|
+
url: '/v2/consumer/blobs/{blobId}',
|
|
33
21
|
});
|
|
34
22
|
};
|
|
35
|
-
exports.createConfiguration = createConfiguration;
|
|
36
23
|
/**
|
|
37
|
-
*
|
|
24
|
+
* Age classification
|
|
25
|
+
* Detects minors in media content. Returns a boolean value indicating whether the content contains minors as well as details on where minors are detected.
|
|
38
26
|
*/
|
|
39
|
-
const
|
|
27
|
+
export const invokeAgeClassificationStepTemplate = (options) => {
|
|
40
28
|
var _a;
|
|
41
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
29
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
42
30
|
...options,
|
|
43
|
-
url: '/v2/
|
|
31
|
+
url: '/v2/consumer/recipes/ageClassification',
|
|
44
32
|
});
|
|
45
33
|
};
|
|
46
|
-
exports.queryConfigurations = queryConfigurations;
|
|
47
34
|
/**
|
|
48
|
-
*
|
|
35
|
+
* Comfy workflows
|
|
36
|
+
* Runs a comfy workflow. Currently there are limited nodes available. Contact support for more information.
|
|
49
37
|
*/
|
|
50
|
-
const
|
|
38
|
+
export const invokeComfyStepTemplate = (options) => {
|
|
51
39
|
var _a;
|
|
52
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
40
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
53
41
|
...options,
|
|
54
|
-
url: '/v2/
|
|
42
|
+
url: '/v2/consumer/recipes/comfy',
|
|
55
43
|
});
|
|
56
44
|
};
|
|
57
|
-
exports.getConfiguration = getConfiguration;
|
|
58
45
|
/**
|
|
59
|
-
*
|
|
46
|
+
* Echo
|
|
47
|
+
* A workflow step that takes a message string and retuns it.
|
|
48
|
+
* /// This step is intended for testing purposes.
|
|
60
49
|
*/
|
|
61
|
-
const
|
|
50
|
+
export const invokeEchoStepTemplate = (options) => {
|
|
62
51
|
var _a;
|
|
63
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
52
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
64
53
|
...options,
|
|
65
|
-
url: '/v2/
|
|
54
|
+
url: '/v2/consumer/recipes/echo',
|
|
66
55
|
});
|
|
67
56
|
};
|
|
68
|
-
exports.deleteConfiguration = deleteConfiguration;
|
|
69
57
|
/**
|
|
70
|
-
*
|
|
58
|
+
* Image Generation
|
|
59
|
+
* Generate images through text/image inputs using any of our supported engines
|
|
71
60
|
*/
|
|
72
|
-
const
|
|
61
|
+
export const invokeImageGenStepTemplate = (options) => {
|
|
73
62
|
var _a;
|
|
74
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
63
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
75
64
|
...options,
|
|
76
|
-
url: '/v2/
|
|
65
|
+
url: '/v2/consumer/recipes/imageGen',
|
|
77
66
|
});
|
|
78
67
|
};
|
|
79
|
-
exports.getResource = getResource;
|
|
80
68
|
/**
|
|
81
|
-
*
|
|
69
|
+
* LORA Training
|
|
70
|
+
* Train LORA's
|
|
82
71
|
*/
|
|
83
|
-
const
|
|
72
|
+
export const invokeImageResourceTrainingStepTemplate = (options) => {
|
|
84
73
|
var _a;
|
|
85
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
74
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
86
75
|
...options,
|
|
87
|
-
url: '/v2/
|
|
76
|
+
url: '/v2/consumer/recipes/imageResourceTraining',
|
|
88
77
|
});
|
|
89
78
|
};
|
|
90
|
-
exports.invalidateResource = invalidateResource;
|
|
91
|
-
const getJobs = (options) => {
|
|
92
|
-
var _a;
|
|
93
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client_fetch_1.client).get({
|
|
94
|
-
...options,
|
|
95
|
-
url: '/v2/providers/workers/{workerId}/jobs',
|
|
96
|
-
});
|
|
97
|
-
};
|
|
98
|
-
exports.getJobs = getJobs;
|
|
99
|
-
const downloadResource = (options) => {
|
|
100
|
-
var _a;
|
|
101
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client_fetch_1.client).get({
|
|
102
|
-
...options,
|
|
103
|
-
url: '/v2/providers/workers/{workerId}/resources/{air}',
|
|
104
|
-
});
|
|
105
|
-
};
|
|
106
|
-
exports.downloadResource = downloadResource;
|
|
107
|
-
/**
|
|
108
|
-
* Create a worker with a given registration.
|
|
109
|
-
*/
|
|
110
|
-
const createWorker = (options) => {
|
|
111
|
-
var _a;
|
|
112
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client_fetch_1.client).post({
|
|
113
|
-
...options,
|
|
114
|
-
url: '/v2/providers/workers',
|
|
115
|
-
});
|
|
116
|
-
};
|
|
117
|
-
exports.createWorker = createWorker;
|
|
118
79
|
/**
|
|
119
|
-
*
|
|
80
|
+
* Image upload
|
|
81
|
+
* Uploads an image to be used in a workflow
|
|
120
82
|
*/
|
|
121
|
-
const
|
|
83
|
+
export const invokeImageUploadStepTemplate = (options) => {
|
|
122
84
|
var _a;
|
|
123
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
85
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
124
86
|
...options,
|
|
125
|
-
url: '/v2/
|
|
87
|
+
url: '/v2/consumer/recipes/imageUpload',
|
|
126
88
|
});
|
|
127
89
|
};
|
|
128
|
-
exports.queryWorkers = queryWorkers;
|
|
129
90
|
/**
|
|
130
|
-
*
|
|
91
|
+
* TextToImage
|
|
92
|
+
* Generate images using text as input
|
|
131
93
|
*/
|
|
132
|
-
const
|
|
94
|
+
export const invokeTextToImageStepTemplate = (options) => {
|
|
133
95
|
var _a;
|
|
134
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
96
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
135
97
|
...options,
|
|
136
|
-
url: '/v2/
|
|
98
|
+
url: '/v2/consumer/recipes/textToImage',
|
|
137
99
|
});
|
|
138
100
|
};
|
|
139
|
-
exports.getWorker = getWorker;
|
|
140
101
|
/**
|
|
141
|
-
*
|
|
102
|
+
* Upscale videos and/or interpolate frames
|
|
142
103
|
*/
|
|
143
|
-
const
|
|
104
|
+
export const invokeVideoEnhancementStepTemplate = (options) => {
|
|
144
105
|
var _a;
|
|
145
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
106
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
146
107
|
...options,
|
|
147
|
-
url: '/v2/
|
|
108
|
+
url: '/v2/consumer/recipes/videoEnhancement',
|
|
148
109
|
});
|
|
149
110
|
};
|
|
150
|
-
exports.deleteWorker = deleteWorker;
|
|
151
111
|
/**
|
|
152
|
-
*
|
|
112
|
+
* Video generation
|
|
113
|
+
* Generate videos through text/image inputs using any of our supported engines
|
|
153
114
|
*/
|
|
154
|
-
const
|
|
115
|
+
export const invokeVideoGenStepTemplate = (options) => {
|
|
155
116
|
var _a;
|
|
156
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
117
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
157
118
|
...options,
|
|
158
|
-
url: '/v2/
|
|
119
|
+
url: '/v2/consumer/recipes/videoGen',
|
|
159
120
|
});
|
|
160
121
|
};
|
|
161
|
-
exports.getRegistration = getRegistration;
|
|
162
122
|
/**
|
|
163
|
-
*
|
|
123
|
+
* Get an existing resource.
|
|
164
124
|
*/
|
|
165
|
-
const
|
|
125
|
+
export const getResource = (options) => {
|
|
166
126
|
var _a;
|
|
167
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
127
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).get({
|
|
168
128
|
...options,
|
|
169
|
-
url: '/v2/
|
|
129
|
+
url: '/v2/resources/{air}',
|
|
170
130
|
});
|
|
171
131
|
};
|
|
172
|
-
exports.updateWorkerRegistration = updateWorkerRegistration;
|
|
173
132
|
/**
|
|
174
|
-
*
|
|
133
|
+
* Invalidates the cache of a specific resource.
|
|
175
134
|
*/
|
|
176
|
-
const
|
|
135
|
+
export const invalidateResource = (options) => {
|
|
177
136
|
var _a;
|
|
178
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
137
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).delete({
|
|
179
138
|
...options,
|
|
180
|
-
url: '/v2/
|
|
139
|
+
url: '/v2/resources/{air}',
|
|
181
140
|
});
|
|
182
141
|
};
|
|
183
|
-
exports.patchWorkerResources = patchWorkerResources;
|
|
184
142
|
/**
|
|
185
|
-
* Submit
|
|
143
|
+
* Submit workflow
|
|
186
144
|
*/
|
|
187
|
-
const submitWorkflow = (options) => {
|
|
145
|
+
export const submitWorkflow = (options) => {
|
|
188
146
|
var _a;
|
|
189
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
147
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
190
148
|
...options,
|
|
191
149
|
url: '/v2/consumer/workflows',
|
|
192
150
|
});
|
|
193
151
|
};
|
|
194
|
-
exports.submitWorkflow = submitWorkflow;
|
|
195
152
|
/**
|
|
196
|
-
* Query
|
|
153
|
+
* Query workflows
|
|
197
154
|
*/
|
|
198
|
-
const queryWorkflows = (options) => {
|
|
155
|
+
export const queryWorkflows = (options) => {
|
|
199
156
|
var _a;
|
|
200
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
157
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).get({
|
|
201
158
|
...options,
|
|
202
159
|
url: '/v2/consumer/workflows',
|
|
203
160
|
});
|
|
204
161
|
};
|
|
205
|
-
exports.queryWorkflows = queryWorkflows;
|
|
206
162
|
/**
|
|
207
|
-
* Get
|
|
163
|
+
* Get workflow
|
|
208
164
|
*/
|
|
209
|
-
const getWorkflow = (options) => {
|
|
165
|
+
export const getWorkflow = (options) => {
|
|
210
166
|
var _a;
|
|
211
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
167
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).get({
|
|
212
168
|
...options,
|
|
213
169
|
url: '/v2/consumer/workflows/{workflowId}',
|
|
214
170
|
});
|
|
215
171
|
};
|
|
216
|
-
exports.getWorkflow = getWorkflow;
|
|
217
172
|
/**
|
|
218
|
-
*
|
|
173
|
+
* Update workflow
|
|
174
|
+
* Updates a worfklow. This can currently be used to cancel a worfklow or override metadata and/or tags
|
|
219
175
|
*/
|
|
220
|
-
const updateWorkflow = (options) => {
|
|
176
|
+
export const updateWorkflow = (options) => {
|
|
221
177
|
var _a;
|
|
222
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
178
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).put({
|
|
223
179
|
...options,
|
|
224
180
|
url: '/v2/consumer/workflows/{workflowId}',
|
|
225
181
|
});
|
|
226
182
|
};
|
|
227
|
-
|
|
228
|
-
|
|
183
|
+
/**
|
|
184
|
+
* Patch workflow
|
|
185
|
+
* Patches a worfklow using JSON Patch. This can currently be used to cancel a worfklow, update metadata and add additional tags
|
|
186
|
+
*/
|
|
187
|
+
export const patchWorkflow = (options) => {
|
|
229
188
|
var _a;
|
|
230
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
189
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).patch({
|
|
231
190
|
...options,
|
|
232
191
|
url: '/v2/consumer/workflows/{workflowId}',
|
|
233
192
|
});
|
|
234
193
|
};
|
|
235
|
-
exports.patchWorkflow = patchWorkflow;
|
|
236
194
|
/**
|
|
237
|
-
*
|
|
195
|
+
* Delete workflow
|
|
196
|
+
* This will delete a workflow. This may trigger a refund if the work requested with this workflow has not yet started
|
|
238
197
|
*/
|
|
239
|
-
const deleteWorkflow = (options) => {
|
|
198
|
+
export const deleteWorkflow = (options) => {
|
|
240
199
|
var _a;
|
|
241
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
200
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).delete({
|
|
242
201
|
...options,
|
|
243
202
|
url: '/v2/consumer/workflows/{workflowId}',
|
|
244
203
|
});
|
|
245
204
|
};
|
|
246
|
-
exports.deleteWorkflow = deleteWorkflow;
|
|
247
205
|
/**
|
|
248
|
-
*
|
|
206
|
+
* Add workflow tag
|
|
207
|
+
* Adds a tag to a workflow
|
|
249
208
|
*/
|
|
250
|
-
const addWorkflowTag = (options) => {
|
|
209
|
+
export const addWorkflowTag = (options) => {
|
|
251
210
|
var _a;
|
|
252
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
211
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).post({
|
|
253
212
|
...options,
|
|
254
213
|
url: '/v2/consumer/workflows/{workflowId}/tags',
|
|
255
214
|
});
|
|
256
215
|
};
|
|
257
|
-
exports.addWorkflowTag = addWorkflowTag;
|
|
258
216
|
/**
|
|
259
|
-
* Delete all tags
|
|
217
|
+
* Delete all workflow tags
|
|
260
218
|
*/
|
|
261
|
-
const removeAllWorkflowTags = (options) => {
|
|
219
|
+
export const removeAllWorkflowTags = (options) => {
|
|
262
220
|
var _a;
|
|
263
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
221
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).delete({
|
|
264
222
|
...options,
|
|
265
223
|
url: '/v2/consumer/workflows/{workflowId}/tags',
|
|
266
224
|
});
|
|
267
225
|
};
|
|
268
|
-
exports.removeAllWorkflowTags = removeAllWorkflowTags;
|
|
269
226
|
/**
|
|
270
|
-
*
|
|
227
|
+
* Delete workflow tag
|
|
271
228
|
*/
|
|
272
|
-
const removeWorkflowTag = (options) => {
|
|
229
|
+
export const removeWorkflowTag = (options) => {
|
|
273
230
|
var _a;
|
|
274
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
231
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).delete({
|
|
275
232
|
...options,
|
|
276
233
|
url: '/v2/consumer/workflows/{workflowId}/tags/{tag}',
|
|
277
234
|
});
|
|
278
235
|
};
|
|
279
|
-
exports.removeWorkflowTag = removeWorkflowTag;
|
|
280
236
|
/**
|
|
281
237
|
* Get the status of a workflow step
|
|
282
238
|
*/
|
|
283
|
-
const getWorkflowStep = (options) => {
|
|
239
|
+
export const getWorkflowStep = (options) => {
|
|
284
240
|
var _a;
|
|
285
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
241
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).get({
|
|
286
242
|
...options,
|
|
287
243
|
url: '/v2/consumer/workflows/{workflowId}/steps/{stepName}',
|
|
288
244
|
});
|
|
289
245
|
};
|
|
290
|
-
exports.getWorkflowStep = getWorkflowStep;
|
|
291
246
|
/**
|
|
292
247
|
* Updates a step within a particular workflow.
|
|
293
248
|
*/
|
|
294
|
-
const updateWorkflowStep = (options) => {
|
|
249
|
+
export const updateWorkflowStep = (options) => {
|
|
295
250
|
var _a;
|
|
296
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
251
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).put({
|
|
297
252
|
...options,
|
|
298
253
|
url: '/v2/consumer/workflows/{workflowId}/steps/{stepName}',
|
|
299
254
|
});
|
|
300
255
|
};
|
|
301
|
-
|
|
302
|
-
const patchWorkflowStep = (options) => {
|
|
256
|
+
export const patchWorkflowStep = (options) => {
|
|
303
257
|
var _a;
|
|
304
|
-
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a :
|
|
258
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).patch({
|
|
305
259
|
...options,
|
|
306
260
|
url: '/v2/consumer/workflows/{workflowId}/steps/{stepName}',
|
|
307
261
|
});
|
|
308
262
|
};
|
|
309
|
-
exports.patchWorkflowStep = patchWorkflowStep;
|
|
@@ -11,10 +11,6 @@ export type AiToolkitTrainingInput = TrainingInput & {
|
|
|
11
11
|
* Note: ai-toolkit uses steps internally, calculated based on epochs, image count, and internal parameters.
|
|
12
12
|
*/
|
|
13
13
|
epochs?: number;
|
|
14
|
-
/**
|
|
15
|
-
* Specify the maximum resolution of training images. If the training images exceed the resolution specified here, they will be scaled down to this resolution
|
|
16
|
-
*/
|
|
17
|
-
resolution?: number | null;
|
|
18
14
|
/**
|
|
19
15
|
* Sets the learning rate for the model. This is the learning rate when performing additional learning on each attention block (and other blocks depending on the setting).
|
|
20
16
|
*/
|
|
@@ -446,7 +442,6 @@ export type Flux1KontextImageGenInput = ImageGenInput & {
|
|
|
446
442
|
prompt: string;
|
|
447
443
|
images?: Array<string>;
|
|
448
444
|
aspectRatio?: '21:9' | '16:9' | '4:3' | '3:2' | '1:1' | '2:3' | '3:4' | '9:16' | '9:21';
|
|
449
|
-
outputFormat?: 'jpeg' | 'png';
|
|
450
445
|
guidanceScale?: number;
|
|
451
446
|
quantity?: number;
|
|
452
447
|
seed?: number | null;
|
|
@@ -562,7 +557,6 @@ export type Flux2ImageGenInput = ImageGenInput & {
|
|
|
562
557
|
prompt: string;
|
|
563
558
|
width?: number;
|
|
564
559
|
height?: number;
|
|
565
|
-
outputFormat?: 'jpeg' | 'png';
|
|
566
560
|
seed?: number | null;
|
|
567
561
|
quantity?: number;
|
|
568
562
|
enablePromptExpansion?: boolean;
|
|
@@ -755,6 +749,7 @@ export type ImageBlob = Blob & {
|
|
|
755
749
|
};
|
|
756
750
|
export type ImageGenInput = {
|
|
757
751
|
engine: string;
|
|
752
|
+
outputFormat?: ImageGenOutputFormat;
|
|
758
753
|
};
|
|
759
754
|
export type ImageGenInputLora = {
|
|
760
755
|
air: string;
|
|
@@ -770,6 +765,12 @@ export type ImageGenOutput = {
|
|
|
770
765
|
*/
|
|
771
766
|
errors?: Array<string> | null;
|
|
772
767
|
};
|
|
768
|
+
export declare const ImageGenOutputFormat: {
|
|
769
|
+
readonly JPEG: 'jpeg';
|
|
770
|
+
readonly PNG: 'png';
|
|
771
|
+
readonly WEB_P: 'webP';
|
|
772
|
+
};
|
|
773
|
+
export type ImageGenOutputFormat = (typeof ImageGenOutputFormat)[keyof typeof ImageGenOutputFormat];
|
|
773
774
|
/**
|
|
774
775
|
* Image Generation
|
|
775
776
|
*/
|
|
@@ -1445,7 +1446,6 @@ export type NanoBananaProImageGenInput = GoogleImageGenInput & {
|
|
|
1445
1446
|
aspectRatio?: '21:9' | '16:9' | '3:2' | '4:3' | '5:4' | '1:1' | '4:5' | '3:4' | '2:3' | '9:16';
|
|
1446
1447
|
numImages?: number;
|
|
1447
1448
|
resolution?: '1K' | '2K' | '4K';
|
|
1448
|
-
outputFormat?: 'jpeg' | 'png' | 'webp';
|
|
1449
1449
|
images?: Array<string>;
|
|
1450
1450
|
} & {
|
|
1451
1451
|
model: 'nano-banana-pro';
|
|
@@ -1512,7 +1512,6 @@ export type OpenAiGpt15ImageGenInput = OpenApiImageGenInput & {
|
|
|
1512
1512
|
quantity?: number;
|
|
1513
1513
|
background?: 'auto' | 'transparent' | 'opaque';
|
|
1514
1514
|
quality?: 'low' | 'medium' | 'high';
|
|
1515
|
-
outputFormat?: 'jpeg' | 'png' | 'webp';
|
|
1516
1515
|
} & {
|
|
1517
1516
|
model: 'gpt-image-1.5';
|
|
1518
1517
|
};
|
|
@@ -1885,12 +1884,14 @@ export type ProblemDetails = {
|
|
|
1885
1884
|
| undefined;
|
|
1886
1885
|
};
|
|
1887
1886
|
export type Qwen20bCreateImageGenInput = Qwen20bImageGenInput & {
|
|
1887
|
+
version?: 'latest' | '2509' | '2512';
|
|
1888
1888
|
width?: number;
|
|
1889
1889
|
height?: number;
|
|
1890
1890
|
} & {
|
|
1891
1891
|
operation: 'createImage';
|
|
1892
1892
|
};
|
|
1893
1893
|
export type Qwen20bEditImageGenInput = Qwen20bImageGenInput & {
|
|
1894
|
+
version?: 'latest' | '2509' | '2511';
|
|
1894
1895
|
images: Array<string>;
|
|
1895
1896
|
readonly width?: number;
|
|
1896
1897
|
readonly height?: number;
|
|
@@ -1899,7 +1900,6 @@ export type Qwen20bEditImageGenInput = Qwen20bImageGenInput & {
|
|
|
1899
1900
|
};
|
|
1900
1901
|
export type Qwen20bImageGenInput = QwenImageGenInput & {
|
|
1901
1902
|
operation: string;
|
|
1902
|
-
diffuserModel?: string;
|
|
1903
1903
|
prompt: string;
|
|
1904
1904
|
negativePrompt?: string | null;
|
|
1905
1905
|
sampleMethod?: SdCppSampleMethod;
|
|
@@ -1908,10 +1908,14 @@ export type Qwen20bImageGenInput = QwenImageGenInput & {
|
|
|
1908
1908
|
cfgScale?: number;
|
|
1909
1909
|
seed?: number | null;
|
|
1910
1910
|
quantity?: number;
|
|
1911
|
+
loras?: {
|
|
1912
|
+
[key: string]: number;
|
|
1913
|
+
};
|
|
1911
1914
|
} & {
|
|
1912
1915
|
model: '20b';
|
|
1913
1916
|
};
|
|
1914
1917
|
export type Qwen20bVariantImageGenInput = Qwen20bImageGenInput & {
|
|
1918
|
+
version?: 'latest' | '2509' | '2512';
|
|
1915
1919
|
/**
|
|
1916
1920
|
* Either A URL, A DataURL or a Base64 string
|
|
1917
1921
|
*/
|
|
@@ -4435,6 +4439,18 @@ export type QueryWorkflowsData = {
|
|
|
4435
4439
|
* When set to true, any blob that has mature won't be available and won't have a URL
|
|
4436
4440
|
*/
|
|
4437
4441
|
hideMatureContent?: boolean;
|
|
4442
|
+
/**
|
|
4443
|
+
* An optional start date to filter workflows created on or after this date
|
|
4444
|
+
*/
|
|
4445
|
+
fromDate?: string;
|
|
4446
|
+
/**
|
|
4447
|
+
* An optional end date to filter workflows created on or before this date
|
|
4448
|
+
*/
|
|
4449
|
+
toDate?: string;
|
|
4450
|
+
/**
|
|
4451
|
+
* When set to true, excludes workflows with Failed, Expired, or Canceled status
|
|
4452
|
+
*/
|
|
4453
|
+
excludeFailed?: boolean;
|
|
4438
4454
|
};
|
|
4439
4455
|
url: '/v2/consumer/workflows';
|
|
4440
4456
|
};
|
|
@@ -95,6 +95,11 @@ export const HumanoidImageMaskCategory = {
|
|
|
95
95
|
UPPER_BODY: 'upperBody',
|
|
96
96
|
LOWER_BODY: 'lowerBody',
|
|
97
97
|
};
|
|
98
|
+
export const ImageGenOutputFormat = {
|
|
99
|
+
JPEG: 'jpeg',
|
|
100
|
+
PNG: 'png',
|
|
101
|
+
WEB_P: 'webP',
|
|
102
|
+
};
|
|
98
103
|
export const ImageResouceTrainingModerationStatus = {
|
|
99
104
|
EVALUATING: 'evaluating',
|
|
100
105
|
UNDER_REVIEW: 'underReview',
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@civitai/client",
|
|
3
|
-
"version": "0.2.0-beta.
|
|
3
|
+
"version": "0.2.0-beta.23",
|
|
4
4
|
"description": "Civitai's javascript client for generating ai content",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -54,4 +54,4 @@
|
|
|
54
54
|
"publishConfig": {
|
|
55
55
|
"access": "public"
|
|
56
56
|
}
|
|
57
|
-
}
|
|
57
|
+
}
|