@squonk/data-manager-client 1.2.3 → 1.2.4-rc.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 (112) hide show
  1. package/accounting/accounting.cjs +31 -13
  2. package/accounting/accounting.cjs.map +1 -1
  3. package/accounting/accounting.d.cts +77 -0
  4. package/accounting/accounting.d.ts +10 -1
  5. package/accounting/accounting.js +29 -11
  6. package/accounting/accounting.js.map +1 -1
  7. package/admin/admin.cjs +67 -27
  8. package/admin/admin.cjs.map +1 -1
  9. package/admin/admin.d.cts +324 -0
  10. package/admin/admin.d.ts +55 -22
  11. package/admin/admin.js +57 -17
  12. package/admin/admin.js.map +1 -1
  13. package/application/application.cjs +23 -13
  14. package/application/application.cjs.map +1 -1
  15. package/application/application.d.cts +57 -0
  16. package/application/application.d.ts +7 -1
  17. package/application/application.js +22 -12
  18. package/application/application.js.map +1 -1
  19. package/{chunk-UZTHSGDT.cjs → chunk-J22A7LHX.cjs} +1 -1
  20. package/chunk-J22A7LHX.cjs.map +1 -0
  21. package/{chunk-3RNIDX7T.js → chunk-UKA7G3OB.js} +1 -1
  22. package/{chunk-3RNIDX7T.js.map → chunk-UKA7G3OB.js.map} +1 -1
  23. package/configuration/configuration.cjs +13 -7
  24. package/configuration/configuration.cjs.map +1 -1
  25. package/configuration/configuration.d.cts +29 -0
  26. package/configuration/configuration.d.ts +4 -1
  27. package/configuration/configuration.js +13 -7
  28. package/configuration/configuration.js.map +1 -1
  29. package/{custom-instance-50c9dd5d.d.ts → custom-instance-3d66fe97.d.ts} +826 -826
  30. package/dataset/dataset.cjs +71 -72
  31. package/dataset/dataset.cjs.map +1 -1
  32. package/dataset/dataset.d.cts +315 -0
  33. package/dataset/dataset.d.ts +46 -16
  34. package/dataset/dataset.js +62 -63
  35. package/dataset/dataset.js.map +1 -1
  36. package/exchange-rate/exchange-rate.cjs +43 -32
  37. package/exchange-rate/exchange-rate.cjs.map +1 -1
  38. package/exchange-rate/exchange-rate.d.cts +180 -0
  39. package/exchange-rate/exchange-rate.d.ts +25 -7
  40. package/exchange-rate/exchange-rate.js +38 -27
  41. package/exchange-rate/exchange-rate.js.map +1 -1
  42. package/file/file.cjs +38 -22
  43. package/file/file.cjs.map +1 -1
  44. package/file/file.d.cts +154 -0
  45. package/file/file.d.ts +25 -10
  46. package/file/file.js +34 -18
  47. package/file/file.js.map +1 -1
  48. package/index.cjs +10 -10
  49. package/index.cjs.map +1 -1
  50. package/index.d.cts +2 -0
  51. package/index.d.ts +1 -1
  52. package/index.js +9 -9
  53. package/index.js.map +1 -1
  54. package/instance/instance.cjs +47 -37
  55. package/instance/instance.cjs.map +1 -1
  56. package/instance/instance.d.cts +215 -0
  57. package/instance/instance.d.ts +33 -12
  58. package/instance/instance.js +41 -31
  59. package/instance/instance.js.map +1 -1
  60. package/job/job.cjs +36 -19
  61. package/job/job.cjs.map +1 -1
  62. package/job/job.d.cts +85 -0
  63. package/job/job.d.ts +10 -1
  64. package/job/job.js +34 -17
  65. package/job/job.js.map +1 -1
  66. package/metadata/metadata.cjs +23 -26
  67. package/metadata/metadata.cjs.map +1 -1
  68. package/metadata/metadata.d.cts +132 -0
  69. package/metadata/metadata.d.ts +19 -7
  70. package/metadata/metadata.js +20 -23
  71. package/metadata/metadata.js.map +1 -1
  72. package/package.json +12 -12
  73. package/project/project.cjs +70 -48
  74. package/project/project.cjs.map +1 -1
  75. package/project/project.d.cts +377 -0
  76. package/project/project.d.ts +61 -25
  77. package/project/project.js +59 -37
  78. package/project/project.js.map +1 -1
  79. package/src/accounting/accounting.ts +179 -194
  80. package/src/admin/admin.ts +590 -735
  81. package/src/application/application.ts +125 -141
  82. package/src/configuration/configuration.ts +72 -60
  83. package/src/data-manager-api.schemas.ts +941 -942
  84. package/src/dataset/dataset.ts +591 -770
  85. package/src/exchange-rate/exchange-rate.ts +362 -478
  86. package/src/file/file.ts +292 -357
  87. package/src/instance/instance.ts +427 -533
  88. package/src/job/job.ts +187 -198
  89. package/src/metadata/metadata.ts +247 -339
  90. package/src/project/project.ts +669 -860
  91. package/src/task/task.ts +181 -202
  92. package/src/type/type.ts +72 -68
  93. package/src/user/user.ts +248 -286
  94. package/task/task.cjs +31 -15
  95. package/task/task.cjs.map +1 -1
  96. package/task/task.d.cts +103 -0
  97. package/task/task.d.ts +10 -1
  98. package/task/task.js +29 -13
  99. package/task/task.js.map +1 -1
  100. package/type/type.cjs +13 -7
  101. package/type/type.cjs.map +1 -1
  102. package/type/type.d.cts +31 -0
  103. package/type/type.d.ts +4 -1
  104. package/type/type.js +13 -7
  105. package/type/type.js.map +1 -1
  106. package/user/user.cjs +39 -28
  107. package/user/user.cjs.map +1 -1
  108. package/user/user.d.cts +104 -0
  109. package/user/user.d.ts +16 -4
  110. package/user/user.js +36 -25
  111. package/user/user.js.map +1 -1
  112. package/chunk-UZTHSGDT.cjs.map +0 -1
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Generated by orval v6.15.0 🍺
2
+ * Generated by orval v6.20.0 🍺
3
3
  * Do not edit manually.
4
4
  * Dataset Manager API
5
5
  * The Dataset Manager API service.
@@ -8,39 +8,44 @@ A service that allows *registered* users to make **Datasets** and associated **M
8
8
 
9
9
  * OpenAPI spec version: 1.2
10
10
  */
11
- import { useQuery, useMutation } from "@tanstack/react-query";
11
+ import {
12
+ useMutation,
13
+ useQuery
14
+ } from '@tanstack/react-query'
12
15
  import type {
13
- UseQueryOptions,
14
- UseMutationOptions,
15
- QueryFunction,
16
16
  MutationFunction,
17
- UseQueryResult,
17
+ QueryFunction,
18
18
  QueryKey,
19
- } from "@tanstack/react-query";
19
+ UseMutationOptions,
20
+ UseQueryOptions,
21
+ UseQueryResult
22
+ } from '@tanstack/react-query'
20
23
  import type {
21
- ServiceErrorsGetResponse,
22
- DmError,
24
+ AdminDeleteJobManifestParams,
23
25
  AdminGetServiceErrorsParams,
24
- AdminUsersGetResponse,
25
26
  AdminGetUsersParams,
26
- AdminUserPutResponse,
27
- UserPatchBodyBody,
28
27
  AdminJobManifestGetResponse,
29
28
  AdminJobManifestLoadPutResponse,
29
+ AdminUsersGetResponse,
30
+ DmError,
30
31
  JobManifestPutBodyBody,
31
- AdminDeleteJobManifestParams,
32
- } from "../data-manager-api.schemas";
33
- import { customInstance } from ".././custom-instance";
34
- import type { ErrorType } from ".././custom-instance";
32
+ ServiceErrorsGetResponse,
33
+ UserAccountDetail,
34
+ UserPatchBodyBody
35
+ } from '../data-manager-api.schemas'
36
+ import { customInstance } from '.././custom-instance';
37
+ import type { ErrorType } from '.././custom-instance';
38
+
35
39
 
36
40
  // eslint-disable-next-line
37
- type SecondParameter<T extends (...args: any) => any> = T extends (
41
+ type SecondParameter<T extends (...args: any) => any> = T extends (
38
42
  config: any,
39
- args: infer P
43
+ args: infer P,
40
44
  ) => any
41
45
  ? P
42
46
  : never;
43
47
 
48
+
44
49
  /**
45
50
  * Displays the existing Service Errors, which can also include acknowledged errors, normally excluded from the list.
46
51
 
@@ -49,79 +54,64 @@ You will need `admin` rights to use this endpoint
49
54
  * @summary Gets Service Errors
50
55
  */
51
56
  export const adminGetServiceErrors = (
52
- params?: AdminGetServiceErrorsParams,
53
- options?: SecondParameter<typeof customInstance>,
54
- signal?: AbortSignal
57
+ params?: AdminGetServiceErrorsParams,
58
+ options?: SecondParameter<typeof customInstance>,signal?: AbortSignal
55
59
  ) => {
56
- return customInstance<ServiceErrorsGetResponse>(
57
- { url: `/admin/service-error`, method: "get", params, signal },
58
- options
59
- );
60
- };
61
-
62
- export const getAdminGetServiceErrorsQueryKey = (
63
- params?: AdminGetServiceErrorsParams
64
- ) => ["data-manager-api", `/admin/service-error`, ...(params ? [params] : [])] as const;
65
-
66
- export const getAdminGetServiceErrorsQueryOptions = <
67
- TData = Awaited<ReturnType<typeof adminGetServiceErrors>>,
68
- TError = ErrorType<void | DmError>
69
- >(
70
- params?: AdminGetServiceErrorsParams,
71
- options?: {
72
- query?: UseQueryOptions<
73
- Awaited<ReturnType<typeof adminGetServiceErrors>>,
74
- TError,
75
- TData
76
- >;
77
- request?: SecondParameter<typeof customInstance>;
78
- }
79
- ): UseQueryOptions<
80
- Awaited<ReturnType<typeof adminGetServiceErrors>>,
81
- TError,
82
- TData
83
- > & { queryKey: QueryKey } => {
84
- const { query: queryOptions, request: requestOptions } = options ?? {};
85
-
86
- const queryKey =
87
- queryOptions?.queryKey ?? getAdminGetServiceErrorsQueryKey(params);
88
-
89
- const queryFn: QueryFunction<
90
- Awaited<ReturnType<typeof adminGetServiceErrors>>
91
- > = ({ signal }) => adminGetServiceErrors(params, requestOptions, signal);
92
-
93
- return { queryKey, queryFn, ...queryOptions };
94
- };
95
-
96
- export type AdminGetServiceErrorsQueryResult = NonNullable<
97
- Awaited<ReturnType<typeof adminGetServiceErrors>>
98
- >;
99
- export type AdminGetServiceErrorsQueryError = ErrorType<void | DmError>;
100
-
101
- export const useAdminGetServiceErrors = <
102
- TData = Awaited<ReturnType<typeof adminGetServiceErrors>>,
103
- TError = ErrorType<void | DmError>
104
- >(
105
- params?: AdminGetServiceErrorsParams,
106
- options?: {
107
- query?: UseQueryOptions<
108
- Awaited<ReturnType<typeof adminGetServiceErrors>>,
109
- TError,
110
- TData
111
- >;
112
- request?: SecondParameter<typeof customInstance>;
113
- }
114
- ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
115
- const queryOptions = getAdminGetServiceErrorsQueryOptions(params, options);
116
-
117
- const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & {
118
- queryKey: QueryKey;
119
- };
120
-
121
- query.queryKey = queryOptions.queryKey;
60
+
61
+
62
+ return customInstance<ServiceErrorsGetResponse>(
63
+ {url: `/admin/service-error`, method: 'get',
64
+ params, signal
65
+ },
66
+ options);
67
+ }
68
+
69
+
70
+ export const getAdminGetServiceErrorsQueryKey = (params?: AdminGetServiceErrorsParams,) => {
71
+
72
+ return ["data-manager-api", `/admin/service-error`, ...(params ? [params]: [])] as const;
73
+ }
74
+
75
+
76
+ export const getAdminGetServiceErrorsQueryOptions = <TData = Awaited<ReturnType<typeof adminGetServiceErrors>>, TError = ErrorType<void | DmError>>(params?: AdminGetServiceErrorsParams, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof adminGetServiceErrors>>, TError, TData>, request?: SecondParameter<typeof customInstance>}
77
+ ) => {
78
+
79
+ const {query: queryOptions, request: requestOptions} = options ?? {};
80
+
81
+ const queryKey = queryOptions?.queryKey ?? getAdminGetServiceErrorsQueryKey(params);
82
+
83
+
84
+
85
+ const queryFn: QueryFunction<Awaited<ReturnType<typeof adminGetServiceErrors>>> = ({ signal }) => adminGetServiceErrors(params, requestOptions, signal);
86
+
87
+
88
+
89
+
90
+
91
+ return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof adminGetServiceErrors>>, TError, TData> & { queryKey: QueryKey }
92
+ }
93
+
94
+ export type AdminGetServiceErrorsQueryResult = NonNullable<Awaited<ReturnType<typeof adminGetServiceErrors>>>
95
+ export type AdminGetServiceErrorsQueryError = ErrorType<void | DmError>
96
+
97
+ /**
98
+ * @summary Gets Service Errors
99
+ */
100
+ export const useAdminGetServiceErrors = <TData = Awaited<ReturnType<typeof adminGetServiceErrors>>, TError = ErrorType<void | DmError>>(
101
+ params?: AdminGetServiceErrorsParams, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof adminGetServiceErrors>>, TError, TData>, request?: SecondParameter<typeof customInstance>}
102
+
103
+ ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
104
+
105
+ const queryOptions = getAdminGetServiceErrorsQueryOptions(params,options)
106
+
107
+ const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };
108
+
109
+ query.queryKey = queryOptions.queryKey ;
122
110
 
123
111
  return query;
124
- };
112
+ }
113
+
114
+
125
115
 
126
116
  /**
127
117
  * Used primarily to 'Acknowledge' but not delete a Service Error.
@@ -131,69 +121,55 @@ You will need `admin` rights to use this endpoint
131
121
  * @summary Patches a Service Error
132
122
  */
133
123
  export const adminPatchServiceError = (
134
- errorId: number,
135
- options?: SecondParameter<typeof customInstance>
124
+ errorId: number,
125
+ options?: SecondParameter<typeof customInstance>,) => {
126
+
127
+
128
+ return customInstance<void>(
129
+ {url: `/admin/service-error/${errorId}`, method: 'patch'
130
+ },
131
+ options);
132
+ }
133
+
134
+
135
+
136
+ export const getAdminPatchServiceErrorMutationOptions = <TError = ErrorType<DmError>,
137
+
138
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminPatchServiceError>>, TError,{errorId: number}, TContext>, request?: SecondParameter<typeof customInstance>}
139
+ ): UseMutationOptions<Awaited<ReturnType<typeof adminPatchServiceError>>, TError,{errorId: number}, TContext> => {
140
+ const {mutation: mutationOptions, request: requestOptions} = options ?? {};
141
+
142
+
143
+
144
+
145
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof adminPatchServiceError>>, {errorId: number}> = (props) => {
146
+ const {errorId} = props ?? {};
147
+
148
+ return adminPatchServiceError(errorId,requestOptions)
149
+ }
150
+
151
+
152
+
153
+
154
+ return { mutationFn, ...mutationOptions }}
155
+
156
+ export type AdminPatchServiceErrorMutationResult = NonNullable<Awaited<ReturnType<typeof adminPatchServiceError>>>
157
+
158
+ export type AdminPatchServiceErrorMutationError = ErrorType<DmError>
159
+
160
+ /**
161
+ * @summary Patches a Service Error
162
+ */
163
+ export const useAdminPatchServiceError = <TError = ErrorType<DmError>,
164
+
165
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminPatchServiceError>>, TError,{errorId: number}, TContext>, request?: SecondParameter<typeof customInstance>}
136
166
  ) => {
137
- return customInstance<void>(
138
- { url: `/admin/service-error/${errorId}`, method: "patch" },
139
- options
140
- );
141
- };
142
-
143
- export const getAdminPatchServiceErrorMutationOptions = <
144
- TError = ErrorType<DmError>,
145
- TContext = unknown
146
- >(options?: {
147
- mutation?: UseMutationOptions<
148
- Awaited<ReturnType<typeof adminPatchServiceError>>,
149
- TError,
150
- { errorId: number },
151
- TContext
152
- >;
153
- request?: SecondParameter<typeof customInstance>;
154
- }): UseMutationOptions<
155
- Awaited<ReturnType<typeof adminPatchServiceError>>,
156
- TError,
157
- { errorId: number },
158
- TContext
159
- > => {
160
- const { mutation: mutationOptions, request: requestOptions } = options ?? {};
161
-
162
- const mutationFn: MutationFunction<
163
- Awaited<ReturnType<typeof adminPatchServiceError>>,
164
- { errorId: number }
165
- > = (props) => {
166
- const { errorId } = props ?? {};
167
-
168
- return adminPatchServiceError(errorId, requestOptions);
169
- };
170
-
171
- return { mutationFn, ...mutationOptions };
172
- };
173
-
174
- export type AdminPatchServiceErrorMutationResult = NonNullable<
175
- Awaited<ReturnType<typeof adminPatchServiceError>>
176
- >;
177
-
178
- export type AdminPatchServiceErrorMutationError = ErrorType<DmError>;
179
-
180
- export const useAdminPatchServiceError = <
181
- TError = ErrorType<DmError>,
182
- TContext = unknown
183
- >(options?: {
184
- mutation?: UseMutationOptions<
185
- Awaited<ReturnType<typeof adminPatchServiceError>>,
186
- TError,
187
- { errorId: number },
188
- TContext
189
- >;
190
- request?: SecondParameter<typeof customInstance>;
191
- }) => {
192
- const mutationOptions = getAdminPatchServiceErrorMutationOptions(options);
193
-
194
- return useMutation(mutationOptions);
195
- };
196
- /**
167
+
168
+ const mutationOptions = getAdminPatchServiceErrorMutationOptions(options);
169
+
170
+ return useMutation(mutationOptions);
171
+ }
172
+ /**
197
173
  * Deletes an existing Service Error.
198
174
 
199
175
  You will need `admin` rights to use this endpoint
@@ -201,143 +177,118 @@ You will need `admin` rights to use this endpoint
201
177
  * @summary Deletes a Service Error
202
178
  */
203
179
  export const adminDeleteServiceError = (
204
- errorId: number,
205
- options?: SecondParameter<typeof customInstance>
180
+ errorId: number,
181
+ options?: SecondParameter<typeof customInstance>,) => {
182
+
183
+
184
+ return customInstance<void>(
185
+ {url: `/admin/service-error/${errorId}`, method: 'delete'
186
+ },
187
+ options);
188
+ }
189
+
190
+
191
+
192
+ export const getAdminDeleteServiceErrorMutationOptions = <TError = ErrorType<DmError>,
193
+
194
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminDeleteServiceError>>, TError,{errorId: number}, TContext>, request?: SecondParameter<typeof customInstance>}
195
+ ): UseMutationOptions<Awaited<ReturnType<typeof adminDeleteServiceError>>, TError,{errorId: number}, TContext> => {
196
+ const {mutation: mutationOptions, request: requestOptions} = options ?? {};
197
+
198
+
199
+
200
+
201
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof adminDeleteServiceError>>, {errorId: number}> = (props) => {
202
+ const {errorId} = props ?? {};
203
+
204
+ return adminDeleteServiceError(errorId,requestOptions)
205
+ }
206
+
207
+
208
+
209
+
210
+ return { mutationFn, ...mutationOptions }}
211
+
212
+ export type AdminDeleteServiceErrorMutationResult = NonNullable<Awaited<ReturnType<typeof adminDeleteServiceError>>>
213
+
214
+ export type AdminDeleteServiceErrorMutationError = ErrorType<DmError>
215
+
216
+ /**
217
+ * @summary Deletes a Service Error
218
+ */
219
+ export const useAdminDeleteServiceError = <TError = ErrorType<DmError>,
220
+
221
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminDeleteServiceError>>, TError,{errorId: number}, TContext>, request?: SecondParameter<typeof customInstance>}
206
222
  ) => {
207
- return customInstance<void>(
208
- { url: `/admin/service-error/${errorId}`, method: "delete" },
209
- options
210
- );
211
- };
212
-
213
- export const getAdminDeleteServiceErrorMutationOptions = <
214
- TError = ErrorType<DmError>,
215
- TContext = unknown
216
- >(options?: {
217
- mutation?: UseMutationOptions<
218
- Awaited<ReturnType<typeof adminDeleteServiceError>>,
219
- TError,
220
- { errorId: number },
221
- TContext
222
- >;
223
- request?: SecondParameter<typeof customInstance>;
224
- }): UseMutationOptions<
225
- Awaited<ReturnType<typeof adminDeleteServiceError>>,
226
- TError,
227
- { errorId: number },
228
- TContext
229
- > => {
230
- const { mutation: mutationOptions, request: requestOptions } = options ?? {};
231
-
232
- const mutationFn: MutationFunction<
233
- Awaited<ReturnType<typeof adminDeleteServiceError>>,
234
- { errorId: number }
235
- > = (props) => {
236
- const { errorId } = props ?? {};
237
-
238
- return adminDeleteServiceError(errorId, requestOptions);
239
- };
240
-
241
- return { mutationFn, ...mutationOptions };
242
- };
243
-
244
- export type AdminDeleteServiceErrorMutationResult = NonNullable<
245
- Awaited<ReturnType<typeof adminDeleteServiceError>>
246
- >;
247
-
248
- export type AdminDeleteServiceErrorMutationError = ErrorType<DmError>;
249
-
250
- export const useAdminDeleteServiceError = <
251
- TError = ErrorType<DmError>,
252
- TContext = unknown
253
- >(options?: {
254
- mutation?: UseMutationOptions<
255
- Awaited<ReturnType<typeof adminDeleteServiceError>>,
256
- TError,
257
- { errorId: number },
258
- TContext
259
- >;
260
- request?: SecondParameter<typeof customInstance>;
261
- }) => {
262
- const mutationOptions = getAdminDeleteServiceErrorMutationOptions(options);
263
-
264
- return useMutation(mutationOptions);
265
- };
266
- /**
223
+
224
+ const mutationOptions = getAdminDeleteServiceErrorMutationOptions(options);
225
+
226
+ return useMutation(mutationOptions);
227
+ }
228
+ /**
267
229
  * You need admin privileges to use this endpoint and you are excluded from the returned list of users
268
230
 
269
231
  * @summary Get detailed information about all known Users
270
232
  */
271
233
  export const adminGetUsers = (
272
- params?: AdminGetUsersParams,
273
- options?: SecondParameter<typeof customInstance>,
274
- signal?: AbortSignal
234
+ params?: AdminGetUsersParams,
235
+ options?: SecondParameter<typeof customInstance>,signal?: AbortSignal
236
+ ) => {
237
+
238
+
239
+ return customInstance<AdminUsersGetResponse>(
240
+ {url: `/admin/user`, method: 'get',
241
+ params, signal
242
+ },
243
+ options);
244
+ }
245
+
246
+
247
+ export const getAdminGetUsersQueryKey = (params?: AdminGetUsersParams,) => {
248
+
249
+ return ["data-manager-api", `/admin/user`, ...(params ? [params]: [])] as const;
250
+ }
251
+
252
+
253
+ export const getAdminGetUsersQueryOptions = <TData = Awaited<ReturnType<typeof adminGetUsers>>, TError = ErrorType<void | DmError>>(params?: AdminGetUsersParams, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof adminGetUsers>>, TError, TData>, request?: SecondParameter<typeof customInstance>}
275
254
  ) => {
276
- return customInstance<AdminUsersGetResponse>(
277
- { url: `/admin/user`, method: "get", params, signal },
278
- options
279
- );
280
- };
281
-
282
- export const getAdminGetUsersQueryKey = (params?: AdminGetUsersParams) =>
283
- ["data-manager-api", `/admin/user`, ...(params ? [params] : [])] as const;
284
-
285
- export const getAdminGetUsersQueryOptions = <
286
- TData = Awaited<ReturnType<typeof adminGetUsers>>,
287
- TError = ErrorType<void | DmError>
288
- >(
289
- params?: AdminGetUsersParams,
290
- options?: {
291
- query?: UseQueryOptions<
292
- Awaited<ReturnType<typeof adminGetUsers>>,
293
- TError,
294
- TData
295
- >;
296
- request?: SecondParameter<typeof customInstance>;
297
- }
298
- ): UseQueryOptions<Awaited<ReturnType<typeof adminGetUsers>>, TError, TData> & {
299
- queryKey: QueryKey;
300
- } => {
301
- const { query: queryOptions, request: requestOptions } = options ?? {};
302
-
303
- const queryKey = queryOptions?.queryKey ?? getAdminGetUsersQueryKey(params);
304
-
305
- const queryFn: QueryFunction<Awaited<ReturnType<typeof adminGetUsers>>> = ({
306
- signal,
307
- }) => adminGetUsers(params, requestOptions, signal);
308
-
309
- return { queryKey, queryFn, ...queryOptions };
310
- };
311
-
312
- export type AdminGetUsersQueryResult = NonNullable<
313
- Awaited<ReturnType<typeof adminGetUsers>>
314
- >;
315
- export type AdminGetUsersQueryError = ErrorType<void | DmError>;
316
-
317
- export const useAdminGetUsers = <
318
- TData = Awaited<ReturnType<typeof adminGetUsers>>,
319
- TError = ErrorType<void | DmError>
320
- >(
321
- params?: AdminGetUsersParams,
322
- options?: {
323
- query?: UseQueryOptions<
324
- Awaited<ReturnType<typeof adminGetUsers>>,
325
- TError,
326
- TData
327
- >;
328
- request?: SecondParameter<typeof customInstance>;
329
- }
330
- ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
331
- const queryOptions = getAdminGetUsersQueryOptions(params, options);
332
-
333
- const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & {
334
- queryKey: QueryKey;
335
- };
336
-
337
- query.queryKey = queryOptions.queryKey;
255
+
256
+ const {query: queryOptions, request: requestOptions} = options ?? {};
257
+
258
+ const queryKey = queryOptions?.queryKey ?? getAdminGetUsersQueryKey(params);
259
+
260
+
261
+
262
+ const queryFn: QueryFunction<Awaited<ReturnType<typeof adminGetUsers>>> = ({ signal }) => adminGetUsers(params, requestOptions, signal);
263
+
264
+
265
+
266
+
267
+
268
+ return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof adminGetUsers>>, TError, TData> & { queryKey: QueryKey }
269
+ }
270
+
271
+ export type AdminGetUsersQueryResult = NonNullable<Awaited<ReturnType<typeof adminGetUsers>>>
272
+ export type AdminGetUsersQueryError = ErrorType<void | DmError>
273
+
274
+ /**
275
+ * @summary Get detailed information about all known Users
276
+ */
277
+ export const useAdminGetUsers = <TData = Awaited<ReturnType<typeof adminGetUsers>>, TError = ErrorType<void | DmError>>(
278
+ params?: AdminGetUsersParams, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof adminGetUsers>>, TError, TData>, request?: SecondParameter<typeof customInstance>}
279
+
280
+ ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
281
+
282
+ const queryOptions = getAdminGetUsersQueryOptions(params,options)
283
+
284
+ const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };
285
+
286
+ query.queryKey = queryOptions.queryKey ;
338
287
 
339
288
  return query;
340
- };
289
+ }
290
+
291
+
341
292
 
342
293
  /**
343
294
  * This method adds a user to the Data Manager service. The user is authenticated via a keycloak server but will need an initialised account before they can create Datasets or Projects.
@@ -347,69 +298,55 @@ You will need `admin` rights to use this endpoint
347
298
  * @summary Prepares a user account in the Data Manager service
348
299
  */
349
300
  export const adminPutUser = (
350
- userId: string,
351
- options?: SecondParameter<typeof customInstance>
301
+ userId: string,
302
+ options?: SecondParameter<typeof customInstance>,) => {
303
+
304
+
305
+ return customInstance<UserAccountDetail>(
306
+ {url: `/admin/user/${userId}`, method: 'put'
307
+ },
308
+ options);
309
+ }
310
+
311
+
312
+
313
+ export const getAdminPutUserMutationOptions = <TError = ErrorType<void | DmError>,
314
+
315
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminPutUser>>, TError,{userId: string}, TContext>, request?: SecondParameter<typeof customInstance>}
316
+ ): UseMutationOptions<Awaited<ReturnType<typeof adminPutUser>>, TError,{userId: string}, TContext> => {
317
+ const {mutation: mutationOptions, request: requestOptions} = options ?? {};
318
+
319
+
320
+
321
+
322
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof adminPutUser>>, {userId: string}> = (props) => {
323
+ const {userId} = props ?? {};
324
+
325
+ return adminPutUser(userId,requestOptions)
326
+ }
327
+
328
+
329
+
330
+
331
+ return { mutationFn, ...mutationOptions }}
332
+
333
+ export type AdminPutUserMutationResult = NonNullable<Awaited<ReturnType<typeof adminPutUser>>>
334
+
335
+ export type AdminPutUserMutationError = ErrorType<void | DmError>
336
+
337
+ /**
338
+ * @summary Prepares a user account in the Data Manager service
339
+ */
340
+ export const useAdminPutUser = <TError = ErrorType<void | DmError>,
341
+
342
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminPutUser>>, TError,{userId: string}, TContext>, request?: SecondParameter<typeof customInstance>}
352
343
  ) => {
353
- return customInstance<AdminUserPutResponse>(
354
- { url: `/admin/user/${userId}`, method: "put" },
355
- options
356
- );
357
- };
358
-
359
- export const getAdminPutUserMutationOptions = <
360
- TError = ErrorType<void | DmError>,
361
- TContext = unknown
362
- >(options?: {
363
- mutation?: UseMutationOptions<
364
- Awaited<ReturnType<typeof adminPutUser>>,
365
- TError,
366
- { userId: string },
367
- TContext
368
- >;
369
- request?: SecondParameter<typeof customInstance>;
370
- }): UseMutationOptions<
371
- Awaited<ReturnType<typeof adminPutUser>>,
372
- TError,
373
- { userId: string },
374
- TContext
375
- > => {
376
- const { mutation: mutationOptions, request: requestOptions } = options ?? {};
377
-
378
- const mutationFn: MutationFunction<
379
- Awaited<ReturnType<typeof adminPutUser>>,
380
- { userId: string }
381
- > = (props) => {
382
- const { userId } = props ?? {};
383
-
384
- return adminPutUser(userId, requestOptions);
385
- };
386
-
387
- return { mutationFn, ...mutationOptions };
388
- };
389
-
390
- export type AdminPutUserMutationResult = NonNullable<
391
- Awaited<ReturnType<typeof adminPutUser>>
392
- >;
393
-
394
- export type AdminPutUserMutationError = ErrorType<void | DmError>;
395
-
396
- export const useAdminPutUser = <
397
- TError = ErrorType<void | DmError>,
398
- TContext = unknown
399
- >(options?: {
400
- mutation?: UseMutationOptions<
401
- Awaited<ReturnType<typeof adminPutUser>>,
402
- TError,
403
- { userId: string },
404
- TContext
405
- >;
406
- request?: SecondParameter<typeof customInstance>;
407
- }) => {
408
- const mutationOptions = getAdminPutUserMutationOptions(options);
409
-
410
- return useMutation(mutationOptions);
411
- };
412
- /**
344
+
345
+ const mutationOptions = getAdminPutUserMutationOptions(options);
346
+
347
+ return useMutation(mutationOptions);
348
+ }
349
+ /**
413
350
  * Deletes a user account, along with all the user's Datasets
414
351
 
415
352
  You will need `admin` rights to use this endpoint
@@ -417,69 +354,55 @@ You will need `admin` rights to use this endpoint
417
354
  * @summary Deletes a user account
418
355
  */
419
356
  export const adminDeleteUser = (
420
- userId: string,
421
- options?: SecondParameter<typeof customInstance>
357
+ userId: string,
358
+ options?: SecondParameter<typeof customInstance>,) => {
359
+
360
+
361
+ return customInstance<void>(
362
+ {url: `/admin/user/${userId}`, method: 'delete'
363
+ },
364
+ options);
365
+ }
366
+
367
+
368
+
369
+ export const getAdminDeleteUserMutationOptions = <TError = ErrorType<DmError>,
370
+
371
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminDeleteUser>>, TError,{userId: string}, TContext>, request?: SecondParameter<typeof customInstance>}
372
+ ): UseMutationOptions<Awaited<ReturnType<typeof adminDeleteUser>>, TError,{userId: string}, TContext> => {
373
+ const {mutation: mutationOptions, request: requestOptions} = options ?? {};
374
+
375
+
376
+
377
+
378
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof adminDeleteUser>>, {userId: string}> = (props) => {
379
+ const {userId} = props ?? {};
380
+
381
+ return adminDeleteUser(userId,requestOptions)
382
+ }
383
+
384
+
385
+
386
+
387
+ return { mutationFn, ...mutationOptions }}
388
+
389
+ export type AdminDeleteUserMutationResult = NonNullable<Awaited<ReturnType<typeof adminDeleteUser>>>
390
+
391
+ export type AdminDeleteUserMutationError = ErrorType<DmError>
392
+
393
+ /**
394
+ * @summary Deletes a user account
395
+ */
396
+ export const useAdminDeleteUser = <TError = ErrorType<DmError>,
397
+
398
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminDeleteUser>>, TError,{userId: string}, TContext>, request?: SecondParameter<typeof customInstance>}
422
399
  ) => {
423
- return customInstance<void>(
424
- { url: `/admin/user/${userId}`, method: "delete" },
425
- options
426
- );
427
- };
428
-
429
- export const getAdminDeleteUserMutationOptions = <
430
- TError = ErrorType<DmError>,
431
- TContext = unknown
432
- >(options?: {
433
- mutation?: UseMutationOptions<
434
- Awaited<ReturnType<typeof adminDeleteUser>>,
435
- TError,
436
- { userId: string },
437
- TContext
438
- >;
439
- request?: SecondParameter<typeof customInstance>;
440
- }): UseMutationOptions<
441
- Awaited<ReturnType<typeof adminDeleteUser>>,
442
- TError,
443
- { userId: string },
444
- TContext
445
- > => {
446
- const { mutation: mutationOptions, request: requestOptions } = options ?? {};
447
-
448
- const mutationFn: MutationFunction<
449
- Awaited<ReturnType<typeof adminDeleteUser>>,
450
- { userId: string }
451
- > = (props) => {
452
- const { userId } = props ?? {};
453
-
454
- return adminDeleteUser(userId, requestOptions);
455
- };
456
-
457
- return { mutationFn, ...mutationOptions };
458
- };
459
-
460
- export type AdminDeleteUserMutationResult = NonNullable<
461
- Awaited<ReturnType<typeof adminDeleteUser>>
462
- >;
463
-
464
- export type AdminDeleteUserMutationError = ErrorType<DmError>;
465
-
466
- export const useAdminDeleteUser = <
467
- TError = ErrorType<DmError>,
468
- TContext = unknown
469
- >(options?: {
470
- mutation?: UseMutationOptions<
471
- Awaited<ReturnType<typeof adminDeleteUser>>,
472
- TError,
473
- { userId: string },
474
- TContext
475
- >;
476
- request?: SecondParameter<typeof customInstance>;
477
- }) => {
478
- const mutationOptions = getAdminDeleteUserMutationOptions(options);
479
-
480
- return useMutation(mutationOptions);
481
- };
482
- /**
400
+
401
+ const mutationOptions = getAdminDeleteUserMutationOptions(options);
402
+
403
+ return useMutation(mutationOptions);
404
+ }
405
+ /**
483
406
  * Patches a user record, typically to suspend or re-enable a user account
484
407
 
485
408
  You will need `admin` rights to use this endpoint
@@ -487,80 +410,62 @@ You will need `admin` rights to use this endpoint
487
410
  * @summary Patch a given user
488
411
  */
489
412
  export const adminPatchUser = (
490
- userId: string,
491
- userPatchBodyBody: UserPatchBodyBody,
492
- options?: SecondParameter<typeof customInstance>
493
- ) => {
494
- const formData = new FormData();
495
- if (userPatchBodyBody.suspend_message !== undefined) {
496
- formData.append("suspend_message", userPatchBodyBody.suspend_message);
497
- }
498
-
499
- return customInstance<void>(
500
- {
501
- url: `/admin/user/${userId}`,
502
- method: "patch",
503
- headers: { "Content-Type": "multipart/form-data" },
504
- data: formData,
413
+ userId: string,
414
+ userPatchBodyBody: UserPatchBodyBody,
415
+ options?: SecondParameter<typeof customInstance>,) => {
416
+
417
+ const formData = new FormData();
418
+ if(userPatchBodyBody.suspend_message !== undefined) {
419
+ formData.append('suspend_message', userPatchBodyBody.suspend_message)
420
+ }
421
+
422
+ return customInstance<void>(
423
+ {url: `/admin/user/${userId}`, method: 'patch',
424
+ headers: {'Content-Type': 'multipart/form-data', },
425
+ data: formData
505
426
  },
506
- options
507
- );
508
- };
509
-
510
- export const getAdminPatchUserMutationOptions = <
511
- TError = ErrorType<DmError>,
512
- TContext = unknown
513
- >(options?: {
514
- mutation?: UseMutationOptions<
515
- Awaited<ReturnType<typeof adminPatchUser>>,
516
- TError,
517
- { userId: string; data: UserPatchBodyBody },
518
- TContext
519
- >;
520
- request?: SecondParameter<typeof customInstance>;
521
- }): UseMutationOptions<
522
- Awaited<ReturnType<typeof adminPatchUser>>,
523
- TError,
524
- { userId: string; data: UserPatchBodyBody },
525
- TContext
526
- > => {
527
- const { mutation: mutationOptions, request: requestOptions } = options ?? {};
528
-
529
- const mutationFn: MutationFunction<
530
- Awaited<ReturnType<typeof adminPatchUser>>,
531
- { userId: string; data: UserPatchBodyBody }
532
- > = (props) => {
533
- const { userId, data } = props ?? {};
534
-
535
- return adminPatchUser(userId, data, requestOptions);
536
- };
537
-
538
- return { mutationFn, ...mutationOptions };
539
- };
540
-
541
- export type AdminPatchUserMutationResult = NonNullable<
542
- Awaited<ReturnType<typeof adminPatchUser>>
543
- >;
544
- export type AdminPatchUserMutationBody = UserPatchBodyBody;
545
- export type AdminPatchUserMutationError = ErrorType<DmError>;
546
-
547
- export const useAdminPatchUser = <
548
- TError = ErrorType<DmError>,
549
- TContext = unknown
550
- >(options?: {
551
- mutation?: UseMutationOptions<
552
- Awaited<ReturnType<typeof adminPatchUser>>,
553
- TError,
554
- { userId: string; data: UserPatchBodyBody },
555
- TContext
556
- >;
557
- request?: SecondParameter<typeof customInstance>;
558
- }) => {
559
- const mutationOptions = getAdminPatchUserMutationOptions(options);
560
-
561
- return useMutation(mutationOptions);
562
- };
563
- /**
427
+ options);
428
+ }
429
+
430
+
431
+
432
+ export const getAdminPatchUserMutationOptions = <TError = ErrorType<DmError>,
433
+
434
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminPatchUser>>, TError,{userId: string;data: UserPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}
435
+ ): UseMutationOptions<Awaited<ReturnType<typeof adminPatchUser>>, TError,{userId: string;data: UserPatchBodyBody}, TContext> => {
436
+ const {mutation: mutationOptions, request: requestOptions} = options ?? {};
437
+
438
+
439
+
440
+
441
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof adminPatchUser>>, {userId: string;data: UserPatchBodyBody}> = (props) => {
442
+ const {userId,data} = props ?? {};
443
+
444
+ return adminPatchUser(userId,data,requestOptions)
445
+ }
446
+
447
+
448
+
449
+
450
+ return { mutationFn, ...mutationOptions }}
451
+
452
+ export type AdminPatchUserMutationResult = NonNullable<Awaited<ReturnType<typeof adminPatchUser>>>
453
+ export type AdminPatchUserMutationBody = UserPatchBodyBody
454
+ export type AdminPatchUserMutationError = ErrorType<DmError>
455
+
456
+ /**
457
+ * @summary Patch a given user
458
+ */
459
+ export const useAdminPatchUser = <TError = ErrorType<DmError>,
460
+
461
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminPatchUser>>, TError,{userId: string;data: UserPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}
462
+ ) => {
463
+
464
+ const mutationOptions = getAdminPatchUserMutationOptions(options);
465
+
466
+ return useMutation(mutationOptions);
467
+ }
468
+ /**
564
469
  * Returns the list of known **Job Manifests** including the time the manifest was last loaded and its load status, a message indicating success or failure.
565
470
 
566
471
  You will need `admin` rights to use this endpoint
@@ -568,70 +473,63 @@ You will need `admin` rights to use this endpoint
568
473
  * @summary Get Job Manifests
569
474
  */
570
475
  export const adminGetJobManifests = (
571
- options?: SecondParameter<typeof customInstance>,
572
- signal?: AbortSignal
476
+
477
+ options?: SecondParameter<typeof customInstance>,signal?: AbortSignal
573
478
  ) => {
574
- return customInstance<AdminJobManifestGetResponse>(
575
- { url: `/admin/job-manifest`, method: "get", signal },
576
- options
577
- );
578
- };
579
-
580
- export const getAdminGetJobManifestsQueryKey = () =>
581
- ["data-manager-api", `/admin/job-manifest`] as const;
582
-
583
- export const getAdminGetJobManifestsQueryOptions = <
584
- TData = Awaited<ReturnType<typeof adminGetJobManifests>>,
585
- TError = ErrorType<void | DmError>
586
- >(options?: {
587
- query?: UseQueryOptions<
588
- Awaited<ReturnType<typeof adminGetJobManifests>>,
589
- TError,
590
- TData
591
- >;
592
- request?: SecondParameter<typeof customInstance>;
593
- }): UseQueryOptions<
594
- Awaited<ReturnType<typeof adminGetJobManifests>>,
595
- TError,
596
- TData
597
- > & { queryKey: QueryKey } => {
598
- const { query: queryOptions, request: requestOptions } = options ?? {};
599
-
600
- const queryKey = queryOptions?.queryKey ?? getAdminGetJobManifestsQueryKey();
601
-
602
- const queryFn: QueryFunction<
603
- Awaited<ReturnType<typeof adminGetJobManifests>>
604
- > = ({ signal }) => adminGetJobManifests(requestOptions, signal);
605
-
606
- return { queryKey, queryFn, ...queryOptions };
607
- };
608
-
609
- export type AdminGetJobManifestsQueryResult = NonNullable<
610
- Awaited<ReturnType<typeof adminGetJobManifests>>
611
- >;
612
- export type AdminGetJobManifestsQueryError = ErrorType<void | DmError>;
613
-
614
- export const useAdminGetJobManifests = <
615
- TData = Awaited<ReturnType<typeof adminGetJobManifests>>,
616
- TError = ErrorType<void | DmError>
617
- >(options?: {
618
- query?: UseQueryOptions<
619
- Awaited<ReturnType<typeof adminGetJobManifests>>,
620
- TError,
621
- TData
622
- >;
623
- request?: SecondParameter<typeof customInstance>;
624
- }): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
625
- const queryOptions = getAdminGetJobManifestsQueryOptions(options);
626
-
627
- const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & {
628
- queryKey: QueryKey;
629
- };
630
-
631
- query.queryKey = queryOptions.queryKey;
479
+
480
+
481
+ return customInstance<AdminJobManifestGetResponse>(
482
+ {url: `/admin/job-manifest`, method: 'get', signal
483
+ },
484
+ options);
485
+ }
486
+
487
+
488
+ export const getAdminGetJobManifestsQueryKey = () => {
489
+
490
+ return ["data-manager-api", `/admin/job-manifest`] as const;
491
+ }
492
+
493
+
494
+ export const getAdminGetJobManifestsQueryOptions = <TData = Awaited<ReturnType<typeof adminGetJobManifests>>, TError = ErrorType<void | DmError>>( options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof adminGetJobManifests>>, TError, TData>, request?: SecondParameter<typeof customInstance>}
495
+ ) => {
496
+
497
+ const {query: queryOptions, request: requestOptions} = options ?? {};
498
+
499
+ const queryKey = queryOptions?.queryKey ?? getAdminGetJobManifestsQueryKey();
500
+
501
+
502
+
503
+ const queryFn: QueryFunction<Awaited<ReturnType<typeof adminGetJobManifests>>> = ({ signal }) => adminGetJobManifests(requestOptions, signal);
504
+
505
+
506
+
507
+
508
+
509
+ return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof adminGetJobManifests>>, TError, TData> & { queryKey: QueryKey }
510
+ }
511
+
512
+ export type AdminGetJobManifestsQueryResult = NonNullable<Awaited<ReturnType<typeof adminGetJobManifests>>>
513
+ export type AdminGetJobManifestsQueryError = ErrorType<void | DmError>
514
+
515
+ /**
516
+ * @summary Get Job Manifests
517
+ */
518
+ export const useAdminGetJobManifests = <TData = Awaited<ReturnType<typeof adminGetJobManifests>>, TError = ErrorType<void | DmError>>(
519
+ options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof adminGetJobManifests>>, TError, TData>, request?: SecondParameter<typeof customInstance>}
520
+
521
+ ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
522
+
523
+ const queryOptions = getAdminGetJobManifestsQueryOptions(options)
524
+
525
+ const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };
526
+
527
+ query.queryKey = queryOptions.queryKey ;
632
528
 
633
529
  return query;
634
- };
530
+ }
531
+
532
+
635
533
 
636
534
  /**
637
535
  * This endpoint is used to add (or update an existing **Job Manifest**). Manifests are the source of Job definitions. Once added the manifest is inspected and any Jobs it refers to are loaded.
@@ -643,83 +541,65 @@ You will need `admin` rights to use this endpoint
643
541
  * @summary Adds a Job Manifest and triggers the download of its Job Definitions
644
542
  */
645
543
  export const adminJobManifestPut = (
646
- jobManifestPutBodyBody: JobManifestPutBodyBody,
647
- options?: SecondParameter<typeof customInstance>
648
- ) => {
649
- const formData = new FormData();
650
- formData.append("url", jobManifestPutBodyBody.url);
651
- if (jobManifestPutBodyBody.header !== undefined) {
652
- formData.append("header", jobManifestPutBodyBody.header);
653
- }
654
- if (jobManifestPutBodyBody.params !== undefined) {
655
- formData.append("params", jobManifestPutBodyBody.params);
656
- }
657
-
658
- return customInstance<AdminJobManifestLoadPutResponse>(
659
- {
660
- url: `/admin/job-manifest`,
661
- method: "put",
662
- headers: { "Content-Type": "multipart/form-data" },
663
- data: formData,
544
+ jobManifestPutBodyBody: JobManifestPutBodyBody,
545
+ options?: SecondParameter<typeof customInstance>,) => {
546
+
547
+ const formData = new FormData();
548
+ formData.append('url', jobManifestPutBodyBody.url)
549
+ if(jobManifestPutBodyBody.header !== undefined) {
550
+ formData.append('header', jobManifestPutBodyBody.header)
551
+ }
552
+ if(jobManifestPutBodyBody.params !== undefined) {
553
+ formData.append('params', jobManifestPutBodyBody.params)
554
+ }
555
+
556
+ return customInstance<AdminJobManifestLoadPutResponse>(
557
+ {url: `/admin/job-manifest`, method: 'put',
558
+ headers: {'Content-Type': 'multipart/form-data', },
559
+ data: formData
664
560
  },
665
- options
666
- );
667
- };
668
-
669
- export const getAdminJobManifestPutMutationOptions = <
670
- TError = ErrorType<void | DmError>,
671
- TContext = unknown
672
- >(options?: {
673
- mutation?: UseMutationOptions<
674
- Awaited<ReturnType<typeof adminJobManifestPut>>,
675
- TError,
676
- { data: JobManifestPutBodyBody },
677
- TContext
678
- >;
679
- request?: SecondParameter<typeof customInstance>;
680
- }): UseMutationOptions<
681
- Awaited<ReturnType<typeof adminJobManifestPut>>,
682
- TError,
683
- { data: JobManifestPutBodyBody },
684
- TContext
685
- > => {
686
- const { mutation: mutationOptions, request: requestOptions } = options ?? {};
687
-
688
- const mutationFn: MutationFunction<
689
- Awaited<ReturnType<typeof adminJobManifestPut>>,
690
- { data: JobManifestPutBodyBody }
691
- > = (props) => {
692
- const { data } = props ?? {};
693
-
694
- return adminJobManifestPut(data, requestOptions);
695
- };
696
-
697
- return { mutationFn, ...mutationOptions };
698
- };
699
-
700
- export type AdminJobManifestPutMutationResult = NonNullable<
701
- Awaited<ReturnType<typeof adminJobManifestPut>>
702
- >;
703
- export type AdminJobManifestPutMutationBody = JobManifestPutBodyBody;
704
- export type AdminJobManifestPutMutationError = ErrorType<void | DmError>;
705
-
706
- export const useAdminJobManifestPut = <
707
- TError = ErrorType<void | DmError>,
708
- TContext = unknown
709
- >(options?: {
710
- mutation?: UseMutationOptions<
711
- Awaited<ReturnType<typeof adminJobManifestPut>>,
712
- TError,
713
- { data: JobManifestPutBodyBody },
714
- TContext
715
- >;
716
- request?: SecondParameter<typeof customInstance>;
717
- }) => {
718
- const mutationOptions = getAdminJobManifestPutMutationOptions(options);
719
-
720
- return useMutation(mutationOptions);
721
- };
722
- /**
561
+ options);
562
+ }
563
+
564
+
565
+
566
+ export const getAdminJobManifestPutMutationOptions = <TError = ErrorType<void | DmError>,
567
+
568
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminJobManifestPut>>, TError,{data: JobManifestPutBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}
569
+ ): UseMutationOptions<Awaited<ReturnType<typeof adminJobManifestPut>>, TError,{data: JobManifestPutBodyBody}, TContext> => {
570
+ const {mutation: mutationOptions, request: requestOptions} = options ?? {};
571
+
572
+
573
+
574
+
575
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof adminJobManifestPut>>, {data: JobManifestPutBodyBody}> = (props) => {
576
+ const {data} = props ?? {};
577
+
578
+ return adminJobManifestPut(data,requestOptions)
579
+ }
580
+
581
+
582
+
583
+
584
+ return { mutationFn, ...mutationOptions }}
585
+
586
+ export type AdminJobManifestPutMutationResult = NonNullable<Awaited<ReturnType<typeof adminJobManifestPut>>>
587
+ export type AdminJobManifestPutMutationBody = JobManifestPutBodyBody
588
+ export type AdminJobManifestPutMutationError = ErrorType<void | DmError>
589
+
590
+ /**
591
+ * @summary Adds a Job Manifest and triggers the download of its Job Definitions
592
+ */
593
+ export const useAdminJobManifestPut = <TError = ErrorType<void | DmError>,
594
+
595
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminJobManifestPut>>, TError,{data: JobManifestPutBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}
596
+ ) => {
597
+
598
+ const mutationOptions = getAdminJobManifestPutMutationOptions(options);
599
+
600
+ return useMutation(mutationOptions);
601
+ }
602
+ /**
723
603
  * Deletes a Job Manifest record
724
604
 
725
605
  You need to exercise caution using this endpoint. You can disrupt the Data Manager **Instance** execution if you delete and purge Jobs while instances of any affected job may be running.
@@ -729,70 +609,57 @@ You will need `admin` rights to use this endpoint and the Data Manager needs to
729
609
  * @summary Deletes a Job Manifest
730
610
  */
731
611
  export const adminDeleteJobManifest = (
732
- jobManifestId: number,
733
- params?: AdminDeleteJobManifestParams,
734
- options?: SecondParameter<typeof customInstance>
612
+ jobManifestId: number,
613
+ params?: AdminDeleteJobManifestParams,
614
+ options?: SecondParameter<typeof customInstance>,) => {
615
+
616
+
617
+ return customInstance<void>(
618
+ {url: `/admin/job-manifest/${jobManifestId}`, method: 'delete',
619
+ params
620
+ },
621
+ options);
622
+ }
623
+
624
+
625
+
626
+ export const getAdminDeleteJobManifestMutationOptions = <TError = ErrorType<DmError>,
627
+
628
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminDeleteJobManifest>>, TError,{jobManifestId: number;params?: AdminDeleteJobManifestParams}, TContext>, request?: SecondParameter<typeof customInstance>}
629
+ ): UseMutationOptions<Awaited<ReturnType<typeof adminDeleteJobManifest>>, TError,{jobManifestId: number;params?: AdminDeleteJobManifestParams}, TContext> => {
630
+ const {mutation: mutationOptions, request: requestOptions} = options ?? {};
631
+
632
+
633
+
634
+
635
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof adminDeleteJobManifest>>, {jobManifestId: number;params?: AdminDeleteJobManifestParams}> = (props) => {
636
+ const {jobManifestId,params} = props ?? {};
637
+
638
+ return adminDeleteJobManifest(jobManifestId,params,requestOptions)
639
+ }
640
+
641
+
642
+
643
+
644
+ return { mutationFn, ...mutationOptions }}
645
+
646
+ export type AdminDeleteJobManifestMutationResult = NonNullable<Awaited<ReturnType<typeof adminDeleteJobManifest>>>
647
+
648
+ export type AdminDeleteJobManifestMutationError = ErrorType<DmError>
649
+
650
+ /**
651
+ * @summary Deletes a Job Manifest
652
+ */
653
+ export const useAdminDeleteJobManifest = <TError = ErrorType<DmError>,
654
+
655
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminDeleteJobManifest>>, TError,{jobManifestId: number;params?: AdminDeleteJobManifestParams}, TContext>, request?: SecondParameter<typeof customInstance>}
735
656
  ) => {
736
- return customInstance<void>(
737
- { url: `/admin/job-manifest/${jobManifestId}`, method: "delete", params },
738
- options
739
- );
740
- };
741
-
742
- export const getAdminDeleteJobManifestMutationOptions = <
743
- TError = ErrorType<DmError>,
744
- TContext = unknown
745
- >(options?: {
746
- mutation?: UseMutationOptions<
747
- Awaited<ReturnType<typeof adminDeleteJobManifest>>,
748
- TError,
749
- { jobManifestId: number; params?: AdminDeleteJobManifestParams },
750
- TContext
751
- >;
752
- request?: SecondParameter<typeof customInstance>;
753
- }): UseMutationOptions<
754
- Awaited<ReturnType<typeof adminDeleteJobManifest>>,
755
- TError,
756
- { jobManifestId: number; params?: AdminDeleteJobManifestParams },
757
- TContext
758
- > => {
759
- const { mutation: mutationOptions, request: requestOptions } = options ?? {};
760
-
761
- const mutationFn: MutationFunction<
762
- Awaited<ReturnType<typeof adminDeleteJobManifest>>,
763
- { jobManifestId: number; params?: AdminDeleteJobManifestParams }
764
- > = (props) => {
765
- const { jobManifestId, params } = props ?? {};
766
-
767
- return adminDeleteJobManifest(jobManifestId, params, requestOptions);
768
- };
769
-
770
- return { mutationFn, ...mutationOptions };
771
- };
772
-
773
- export type AdminDeleteJobManifestMutationResult = NonNullable<
774
- Awaited<ReturnType<typeof adminDeleteJobManifest>>
775
- >;
776
-
777
- export type AdminDeleteJobManifestMutationError = ErrorType<DmError>;
778
-
779
- export const useAdminDeleteJobManifest = <
780
- TError = ErrorType<DmError>,
781
- TContext = unknown
782
- >(options?: {
783
- mutation?: UseMutationOptions<
784
- Awaited<ReturnType<typeof adminDeleteJobManifest>>,
785
- TError,
786
- { jobManifestId: number; params?: AdminDeleteJobManifestParams },
787
- TContext
788
- >;
789
- request?: SecondParameter<typeof customInstance>;
790
- }) => {
791
- const mutationOptions = getAdminDeleteJobManifestMutationOptions(options);
792
-
793
- return useMutation(mutationOptions);
794
- };
795
- /**
657
+
658
+ const mutationOptions = getAdminDeleteJobManifestMutationOptions(options);
659
+
660
+ return useMutation(mutationOptions);
661
+ }
662
+ /**
796
663
  * This endpoint is used to trigger the Data Manager to re-inspect the internal **Job Manifest** table and download the manifests and reprocess the related job definitions. This is normally done by an administrator when the Manifest table has been modified or if external job definitions are known to have changed in the referenced repositories.
797
664
 
798
665
  You need to exercise caution using this endpoint. You can disrupt the Data Manager **Instance** execution if you re-load Jobs while instances of any affected job may be running.
@@ -802,64 +669,52 @@ You will need `admin` rights to use this endpoint and the Data Manager needs to
802
669
  * @summary Trigger a download of Job Definitions using existing Job Manifests
803
670
  */
804
671
  export const adminJobManifestLoad = (
805
- options?: SecondParameter<typeof customInstance>
672
+
673
+ options?: SecondParameter<typeof customInstance>,) => {
674
+
675
+
676
+ return customInstance<AdminJobManifestLoadPutResponse>(
677
+ {url: `/admin/job-manifest/load`, method: 'put'
678
+ },
679
+ options);
680
+ }
681
+
682
+
683
+
684
+ export const getAdminJobManifestLoadMutationOptions = <TError = ErrorType<void | DmError>,
685
+ TVariables = void,
686
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminJobManifestLoad>>, TError,TVariables, TContext>, request?: SecondParameter<typeof customInstance>}
687
+ ): UseMutationOptions<Awaited<ReturnType<typeof adminJobManifestLoad>>, TError,TVariables, TContext> => {
688
+ const {mutation: mutationOptions, request: requestOptions} = options ?? {};
689
+
690
+
691
+
692
+
693
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof adminJobManifestLoad>>, TVariables> = () => {
694
+
695
+
696
+ return adminJobManifestLoad(requestOptions)
697
+ }
698
+
699
+
700
+
701
+
702
+ return { mutationFn, ...mutationOptions }}
703
+
704
+ export type AdminJobManifestLoadMutationResult = NonNullable<Awaited<ReturnType<typeof adminJobManifestLoad>>>
705
+
706
+ export type AdminJobManifestLoadMutationError = ErrorType<void | DmError>
707
+
708
+ /**
709
+ * @summary Trigger a download of Job Definitions using existing Job Manifests
710
+ */
711
+ export const useAdminJobManifestLoad = <TError = ErrorType<void | DmError>,
712
+ TVariables = void,
713
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof adminJobManifestLoad>>, TError,TVariables, TContext>, request?: SecondParameter<typeof customInstance>}
806
714
  ) => {
807
- return customInstance<AdminJobManifestLoadPutResponse>(
808
- { url: `/admin/job-manifest/load`, method: "put" },
809
- options
810
- );
811
- };
812
-
813
- export const getAdminJobManifestLoadMutationOptions = <
814
- TError = ErrorType<void | DmError>,
815
- TVariables = void,
816
- TContext = unknown
817
- >(options?: {
818
- mutation?: UseMutationOptions<
819
- Awaited<ReturnType<typeof adminJobManifestLoad>>,
820
- TError,
821
- TVariables,
822
- TContext
823
- >;
824
- request?: SecondParameter<typeof customInstance>;
825
- }): UseMutationOptions<
826
- Awaited<ReturnType<typeof adminJobManifestLoad>>,
827
- TError,
828
- TVariables,
829
- TContext
830
- > => {
831
- const { mutation: mutationOptions, request: requestOptions } = options ?? {};
832
-
833
- const mutationFn: MutationFunction<
834
- Awaited<ReturnType<typeof adminJobManifestLoad>>,
835
- TVariables
836
- > = () => {
837
- return adminJobManifestLoad(requestOptions);
838
- };
839
-
840
- return { mutationFn, ...mutationOptions };
841
- };
842
-
843
- export type AdminJobManifestLoadMutationResult = NonNullable<
844
- Awaited<ReturnType<typeof adminJobManifestLoad>>
845
- >;
846
-
847
- export type AdminJobManifestLoadMutationError = ErrorType<void | DmError>;
848
-
849
- export const useAdminJobManifestLoad = <
850
- TError = ErrorType<void | DmError>,
851
- TVariables = void,
852
- TContext = unknown
853
- >(options?: {
854
- mutation?: UseMutationOptions<
855
- Awaited<ReturnType<typeof adminJobManifestLoad>>,
856
- TError,
857
- TVariables,
858
- TContext
859
- >;
860
- request?: SecondParameter<typeof customInstance>;
861
- }) => {
862
- const mutationOptions = getAdminJobManifestLoadMutationOptions(options);
863
-
864
- return useMutation(mutationOptions);
865
- };
715
+
716
+ const mutationOptions = getAdminJobManifestLoadMutationOptions(options);
717
+
718
+ return useMutation(mutationOptions);
719
+ }
720
+