@civitai/client 0.1.9-beta.9 → 0.2.0-beta.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.
Files changed (73) hide show
  1. package/README.md +0 -0
  2. package/dist/client/CivitaiClient.d.ts +2 -1
  3. package/dist/client/CivitaiClient.js +13 -13
  4. package/dist/generated/client/client.d.ts +2 -0
  5. package/dist/generated/client/client.js +145 -0
  6. package/dist/generated/client/index.d.ts +22 -0
  7. package/dist/generated/client/index.js +4 -0
  8. package/dist/generated/client/types.d.ts +185 -0
  9. package/dist/generated/client/utils.d.ts +72 -0
  10. package/dist/generated/client/utils.js +285 -0
  11. package/dist/generated/client.gen.d.ts +14 -0
  12. package/dist/generated/client.gen.js +3 -0
  13. package/dist/generated/core/auth.d.ts +21 -0
  14. package/dist/generated/core/auth.js +13 -0
  15. package/dist/generated/core/bodySerializer.d.ts +17 -0
  16. package/dist/generated/core/bodySerializer.js +53 -0
  17. package/dist/generated/core/params.d.ts +38 -0
  18. package/dist/generated/core/params.js +88 -0
  19. package/dist/generated/core/pathSerializer.d.ts +49 -0
  20. package/dist/generated/core/pathSerializer.js +105 -0
  21. package/dist/generated/core/types.d.ts +89 -0
  22. package/dist/generated/core/types.js +1 -0
  23. package/dist/generated/index.d.ts +1 -2
  24. package/dist/generated/index.js +2 -6
  25. package/dist/generated/schemas.gen.d.ts +2083 -2028
  26. package/dist/generated/schemas.gen.js +2093 -2031
  27. package/dist/generated/sdk.gen.d.ts +370 -0
  28. package/dist/generated/sdk.gen.js +472 -0
  29. package/dist/generated/services.gen.d.ts +88 -90
  30. package/dist/generated/services.gen.js +100 -147
  31. package/dist/generated/types.gen.d.ts +1545 -1982
  32. package/dist/generated/types.gen.js +70 -134
  33. package/dist/index.js +3 -6
  34. package/dist/utils/Air.js +2 -6
  35. package/dist/utils/TimeSpan.js +24 -28
  36. package/dist/utils/handleError.d.ts +2 -0
  37. package/dist/utils/handleError.js +9 -0
  38. package/dist/utils/index.d.ts +1 -0
  39. package/dist/utils/index.js +4 -6
  40. package/dist/utils/patch-json.js +19 -8
  41. package/dist/utils/types.d.ts +3 -0
  42. package/dist/utils/types.js +1 -0
  43. package/package.json +5 -3
  44. package/dist/client/RequestsClient.d.ts +0 -0
  45. package/dist/client/RequestsClient.js +0 -58
  46. package/dist/generated/GeneratedClient.d.ts +0 -22
  47. package/dist/generated/GeneratedClient.js +0 -40
  48. package/dist/generated/core/ApiError.d.ts +0 -10
  49. package/dist/generated/core/ApiError.js +0 -15
  50. package/dist/generated/core/ApiRequestOptions.d.ts +0 -13
  51. package/dist/generated/core/ApiRequestOptions.js +0 -2
  52. package/dist/generated/core/ApiResult.d.ts +0 -7
  53. package/dist/generated/core/ApiResult.js +0 -2
  54. package/dist/generated/core/AxiosHttpRequest.d.ts +0 -14
  55. package/dist/generated/core/AxiosHttpRequest.js +0 -20
  56. package/dist/generated/core/BaseHttpRequest.d.ts +0 -8
  57. package/dist/generated/core/BaseHttpRequest.js +0 -9
  58. package/dist/generated/core/CancelablePromise.d.ts +0 -37
  59. package/dist/generated/core/CancelablePromise.js +0 -93
  60. package/dist/generated/core/FetchHttpRequest.d.ts +0 -14
  61. package/dist/generated/core/FetchHttpRequest.js +0 -20
  62. package/dist/generated/core/OpenAPI.d.ts +0 -27
  63. package/dist/generated/core/OpenAPI.js +0 -33
  64. package/dist/generated/core/request.d.ts +0 -49
  65. package/dist/generated/core/request.js +0 -325
  66. package/dist/generated/enums.gen.d.ts +0 -97
  67. package/dist/generated/enums.gen.js +0 -101
  68. package/dist/utils/CivitaiClientError.d.ts +0 -0
  69. package/dist/utils/CivitaiClientError.js +0 -4
  70. package/dist/utils/CivitaiError.d.ts +0 -5
  71. package/dist/utils/CivitaiError.js +0 -13
  72. package/dist/utils/createClient.js +0 -119
  73. /package/dist/{utils/createClient.d.ts → generated/client/types.js} +0 -0
@@ -1,23 +1,20 @@
1
1
  import { type Options } from '@hey-api/client-fetch';
2
2
  import type {
3
- PutV2ProvidersBlobsByBlobKeyData,
4
3
  GetBlobData,
5
- CreateConfigurationData,
6
- GetConfigurationData,
7
- DeleteConfigurationData,
4
+ HeadBlobData,
5
+ InvokeAgeClassificationStepTemplateData,
6
+ InvokeComfyStepTemplateData,
7
+ InvokeEchoStepTemplateData,
8
+ InvokeImageGenStepTemplateData,
9
+ InvokeImageResourceTrainingStepTemplateData,
10
+ InvokeImageUploadStepTemplateData,
11
+ InvokeTextToImageStepTemplateData,
12
+ InvokeVideoEnhancementStepTemplateData,
13
+ InvokeVideoGenStepTemplateData,
8
14
  GetResourceData,
9
15
  InvalidateResourceData,
10
- GetJobsData,
11
- GetJobsResponse,
12
- DownloadResourceData,
13
- CreateWorkerData,
14
- QueryWorkersResponse,
15
- GetWorkerData,
16
- DeleteWorkerData,
17
- GetRegistrationData,
18
- UpdateWorkerRegistrationData,
19
- PatchWorkerResourcesData,
20
16
  SubmitWorkflowData,
17
+ SubmitWorkflowError,
21
18
  QueryWorkflowsData,
22
19
  GetWorkflowData,
23
20
  UpdateWorkflowData,
@@ -33,140 +30,134 @@ import type {
33
30
  UpdateWorkflowStepData,
34
31
  PatchWorkflowStepData,
35
32
  } from './types.gen';
36
- export declare const putV2ProvidersBlobsByBlobKey: (
37
- options: Options<PutV2ProvidersBlobsByBlobKeyData>
38
- ) => import('@hey-api/client-fetch').RequestResult<unknown, import('./types.gen').ProblemDetails>;
39
33
  /**
40
- * Get blob by ID.
34
+ * Get blob by ID. This will return the blob as a binary stream.
41
35
  */
42
36
  export declare const getBlob: (
43
37
  options: Options<GetBlobData>
44
38
  ) => import('@hey-api/client-fetch').RequestResult<void, unknown>;
45
39
  /**
46
- * Create a new configuration.
40
+ * Handles HTTP HEAD requests for a specific blob, checking its existence and NSFW level.
47
41
  */
48
- export declare const createConfiguration: (
49
- options?: Options<CreateConfigurationData>
42
+ export declare const headBlob: (
43
+ options: Options<HeadBlobData>
44
+ ) => import('@hey-api/client-fetch').RequestResult<void, import('./types.gen').ProblemDetails>;
45
+ /**
46
+ * Age classification
47
+ * Detects minors in media content. Returns a boolean value indicating whether the content contains minors as well as details on where minors are detected.
48
+ */
49
+ export declare const invokeAgeClassificationStepTemplate: (
50
+ options?: Options<InvokeAgeClassificationStepTemplateData>
50
51
  ) => import('@hey-api/client-fetch').RequestResult<
51
- import('./types.gen').CreateConfigurationResult,
52
+ import('./types.gen').AgeClassificationOutput,
52
53
  import('./types.gen').ProblemDetails
53
54
  >;
54
55
  /**
55
- * Query for existing configurations.
56
+ * Comfy workflows
57
+ * Runs a comfy workflow. Currently there are limited nodes available. Contact support for more information.
56
58
  */
57
- export declare const queryConfigurations: (
58
- options?: Options
59
+ export declare const invokeComfyStepTemplate: (
60
+ options?: Options<InvokeComfyStepTemplateData>
59
61
  ) => import('@hey-api/client-fetch').RequestResult<
60
- import('./types.gen').ConfigurationStatus,
62
+ import('./types.gen').ComfyOutput,
61
63
  import('./types.gen').ProblemDetails
62
64
  >;
63
65
  /**
64
- * Get options for a configuration.
66
+ * Echo
67
+ * A workflow step that takes a message string and retuns it.
68
+ * /// This step is intended for testing purposes.
65
69
  */
66
- export declare const getConfiguration: (
67
- options: Options<GetConfigurationData>
70
+ export declare const invokeEchoStepTemplate: (
71
+ options?: Options<InvokeEchoStepTemplateData>
68
72
  ) => import('@hey-api/client-fetch').RequestResult<
69
- import('./types.gen').ConfigurationOptions,
73
+ import('./types.gen').EchoOutput,
70
74
  import('./types.gen').ProblemDetails
71
75
  >;
72
76
  /**
73
- * Delete a configuration.
74
- */
75
- export declare const deleteConfiguration: (
76
- options: Options<DeleteConfigurationData>
77
- ) => import('@hey-api/client-fetch').RequestResult<unknown, import('./types.gen').ProblemDetails>;
78
- /**
79
- * Get an existing resource.
77
+ * Image Generation
78
+ * Generate images through text/image inputs using any of our supported engines
80
79
  */
81
- export declare const getResource: (
82
- options: Options<GetResourceData>
80
+ export declare const invokeImageGenStepTemplate: (
81
+ options?: Options<InvokeImageGenStepTemplateData>
83
82
  ) => import('@hey-api/client-fetch').RequestResult<
84
- import('./types.gen').ResourceInfo,
83
+ import('./types.gen').ImageGenOutput,
85
84
  import('./types.gen').ProblemDetails
86
85
  >;
87
86
  /**
88
- * Invalidates the cache of a specific resource.
87
+ * LORA Training
88
+ * Train LORA's
89
89
  */
90
- export declare const invalidateResource: (
91
- options: Options<InvalidateResourceData>
92
- ) => import('@hey-api/client-fetch').RequestResult<void, import('./types.gen').ProblemDetails>;
93
- export declare const getJobs: (
94
- options: Options<GetJobsData>
90
+ export declare const invokeImageResourceTrainingStepTemplate: (
91
+ options?: Options<InvokeImageResourceTrainingStepTemplateData>
95
92
  ) => import('@hey-api/client-fetch').RequestResult<
96
- GetJobsResponse,
93
+ import('./types.gen').ImageResourceTrainingOutput,
97
94
  import('./types.gen').ProblemDetails
98
95
  >;
99
- export declare const downloadResource: (
100
- options: Options<DownloadResourceData>
96
+ /**
97
+ * Image upload
98
+ * Uploads an image to be used in a workflow
99
+ */
100
+ export declare const invokeImageUploadStepTemplate: (
101
+ options?: Options<InvokeImageUploadStepTemplateData>
101
102
  ) => import('@hey-api/client-fetch').RequestResult<
102
- import('./types.gen').ProblemDetails,
103
+ import('./types.gen').ImageUploadOutput,
103
104
  import('./types.gen').ProblemDetails
104
105
  >;
105
106
  /**
106
- * Create a worker with a given registration.
107
+ * TextToImage
108
+ * Generate images using text as input
107
109
  */
108
- export declare const createWorker: (
109
- options?: Options<CreateWorkerData>
110
+ export declare const invokeTextToImageStepTemplate: (
111
+ options?: Options<InvokeTextToImageStepTemplateData>
110
112
  ) => import('@hey-api/client-fetch').RequestResult<
111
- import('./types.gen').CreateWorkerResult,
113
+ import('./types.gen').TextToImageOutput,
112
114
  import('./types.gen').ProblemDetails
113
115
  >;
114
116
  /**
115
- * Query existing workers.
117
+ * Upscale videos and/or interpolate frames
116
118
  */
117
- export declare const queryWorkers: (
118
- options?: Options
119
+ export declare const invokeVideoEnhancementStepTemplate: (
120
+ options?: Options<InvokeVideoEnhancementStepTemplateData>
119
121
  ) => import('@hey-api/client-fetch').RequestResult<
120
- QueryWorkersResponse,
122
+ import('./types.gen').VideoEnhancementOutput,
121
123
  import('./types.gen').ProblemDetails
122
124
  >;
123
125
  /**
124
- * Gets the worker for the provided ID.
126
+ * Video generation
127
+ * Generate videos through text/image inputs using any of our supported engines
125
128
  */
126
- export declare const getWorker: (
127
- options: Options<GetWorkerData>
129
+ export declare const invokeVideoGenStepTemplate: (
130
+ options?: Options<InvokeVideoGenStepTemplateData>
128
131
  ) => import('@hey-api/client-fetch').RequestResult<
129
- import('./types.gen').WorkerDetails,
132
+ import('./types.gen').VideoGenOutput,
130
133
  import('./types.gen').ProblemDetails
131
134
  >;
132
135
  /**
133
- * Delete a worker.
134
- */
135
- export declare const deleteWorker: (
136
- options: Options<DeleteWorkerData>
137
- ) => import('@hey-api/client-fetch').RequestResult<void, import('./types.gen').ProblemDetails>;
138
- /**
139
- * Gets the registration details for the specified worker.
136
+ * Get an existing resource.
140
137
  */
141
- export declare const getRegistration: (
142
- options: Options<GetRegistrationData>
138
+ export declare const getResource: (
139
+ options: Options<GetResourceData>
143
140
  ) => import('@hey-api/client-fetch').RequestResult<
144
- import('./types.gen').WorkerRegistration,
141
+ import('./types.gen').ResourceInfo,
145
142
  import('./types.gen').ProblemDetails
146
143
  >;
147
144
  /**
148
- * Update the registration details of the specified worker.
149
- */
150
- export declare const updateWorkerRegistration: (
151
- options: Options<UpdateWorkerRegistrationData>
152
- ) => import('@hey-api/client-fetch').RequestResult<void, import('./types.gen').ProblemDetails>;
153
- /**
154
- * Patch a worker's registration resources
145
+ * Invalidates the cache of a specific resource.
155
146
  */
156
- export declare const patchWorkerResources: (
157
- options: Options<PatchWorkerResourcesData>
147
+ export declare const invalidateResource: (
148
+ options: Options<InvalidateResourceData>
158
149
  ) => import('@hey-api/client-fetch').RequestResult<void, import('./types.gen').ProblemDetails>;
159
150
  /**
160
- * Submit a workflow for processing
151
+ * Submit workflow
161
152
  */
162
153
  export declare const submitWorkflow: (
163
154
  options?: Options<SubmitWorkflowData>
164
155
  ) => import('@hey-api/client-fetch').RequestResult<
165
156
  import('./types.gen').Workflow,
166
- import('./types.gen').ProblemDetails
157
+ SubmitWorkflowError
167
158
  >;
168
159
  /**
169
- * Query for workflows made by the user.
160
+ * Query workflows
170
161
  */
171
162
  export declare const queryWorkflows: (
172
163
  options?: Options<QueryWorkflowsData>
@@ -175,7 +166,7 @@ export declare const queryWorkflows: (
175
166
  import('./types.gen').ProblemDetails
176
167
  >;
177
168
  /**
178
- * Get the status of a workflow
169
+ * Get workflow
179
170
  */
180
171
  export declare const getWorkflow: (
181
172
  options: Options<GetWorkflowData>
@@ -184,34 +175,41 @@ export declare const getWorkflow: (
184
175
  import('./types.gen').ProblemDetails
185
176
  >;
186
177
  /**
187
- * Updates a worfklow. This can currently be used to cancel a worfklow.
178
+ * Update workflow
179
+ * Updates a worfklow. This can currently be used to cancel a worfklow or override metadata and/or tags
188
180
  */
189
181
  export declare const updateWorkflow: (
190
182
  options: Options<UpdateWorkflowData>
191
183
  ) => import('@hey-api/client-fetch').RequestResult<void, import('./types.gen').ProblemDetails>;
184
+ /**
185
+ * Patch workflow
186
+ * Patches a worfklow using JSON Patch. This can currently be used to cancel a worfklow, update metadata and add additional tags
187
+ */
192
188
  export declare const patchWorkflow: (
193
189
  options: Options<PatchWorkflowData>
194
190
  ) => import('@hey-api/client-fetch').RequestResult<void, import('./types.gen').ProblemDetails>;
195
191
  /**
196
- * Deletes a workflow and all its jobs.
192
+ * Delete workflow
193
+ * This will delete a workflow. This may trigger a refund if the work requested with this workflow has not yet started
197
194
  */
198
195
  export declare const deleteWorkflow: (
199
196
  options: Options<DeleteWorkflowData>
200
197
  ) => import('@hey-api/client-fetch').RequestResult<void, import('./types.gen').ProblemDetails>;
201
198
  /**
202
- * Submit a tag to be added to a workflow.
199
+ * Add workflow tag
200
+ * Adds a tag to a workflow
203
201
  */
204
202
  export declare const addWorkflowTag: (
205
203
  options: Options<AddWorkflowTagData>
206
204
  ) => import('@hey-api/client-fetch').RequestResult<void, AddWorkflowTagError>;
207
205
  /**
208
- * Delete all tags for a workflow.
206
+ * Delete all workflow tags
209
207
  */
210
208
  export declare const removeAllWorkflowTags: (
211
209
  options: Options<RemoveAllWorkflowTagsData>
212
210
  ) => import('@hey-api/client-fetch').RequestResult<void, RemoveAllWorkflowTagsError>;
213
211
  /**
214
- * Submit a tag to be removed from a workflow.
212
+ * Delete workflow tag
215
213
  */
216
214
  export declare const removeWorkflowTag: (
217
215
  options: Options<RemoveWorkflowTagData>