@squonk/account-server-client 0.1.24-rc.1 → 0.1.27-rc.1

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 (51) hide show
  1. package/{custom-instance-4a108741.d.ts → account-server-api.schemas-e6c5f956.d.ts} +15 -20
  2. package/{chunk-JR7F532L.js → chunk-GWBPVOL2.js} +2 -23
  3. package/chunk-GWBPVOL2.js.map +1 -0
  4. package/chunk-N3RLW53G.cjs +25 -0
  5. package/chunk-N3RLW53G.cjs.map +1 -0
  6. package/index.cjs +21 -5
  7. package/index.cjs.map +1 -1
  8. package/index.d.ts +20 -2
  9. package/index.js +21 -5
  10. package/index.js.map +1 -1
  11. package/organisation/organisation.cjs +31 -31
  12. package/organisation/organisation.cjs.map +1 -1
  13. package/organisation/organisation.d.ts +37 -28
  14. package/organisation/organisation.js +38 -38
  15. package/organisation/organisation.js.map +1 -1
  16. package/package.json +14 -14
  17. package/product/product.cjs +64 -61
  18. package/product/product.cjs.map +1 -1
  19. package/product/product.d.ts +70 -40
  20. package/product/product.js +75 -72
  21. package/product/product.js.map +1 -1
  22. package/service/service.cjs +23 -21
  23. package/service/service.cjs.map +1 -1
  24. package/service/service.d.ts +19 -15
  25. package/service/service.js +26 -24
  26. package/service/service.js.map +1 -1
  27. package/src/account-server-api.schemas.ts +14 -1
  28. package/src/organisation/organisation.ts +86 -83
  29. package/src/product/product.ts +210 -145
  30. package/src/service/service.ts +64 -56
  31. package/src/state/state.ts +31 -32
  32. package/src/unit/unit.ts +170 -149
  33. package/src/user/user.ts +171 -160
  34. package/state/state.cjs +12 -12
  35. package/state/state.cjs.map +1 -1
  36. package/state/state.d.ts +12 -10
  37. package/state/state.js +13 -13
  38. package/state/state.js.map +1 -1
  39. package/unit/unit.cjs +54 -58
  40. package/unit/unit.cjs.map +1 -1
  41. package/unit/unit.d.ts +64 -49
  42. package/unit/unit.js +67 -71
  43. package/unit/unit.js.map +1 -1
  44. package/user/user.cjs +56 -56
  45. package/user/user.cjs.map +1 -1
  46. package/user/user.d.ts +69 -55
  47. package/user/user.js +69 -69
  48. package/user/user.js.map +1 -1
  49. package/chunk-3DXYUDZH.cjs +0 -46
  50. package/chunk-3DXYUDZH.cjs.map +0 -1
  51. package/chunk-JR7F532L.js.map +0 -1
package/src/unit/unit.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Generated by orval v6.6.0 🍺
2
+ * Generated by orval v6.7.1 🍺
3
3
  * Do not edit manually.
4
4
  * Account Server API
5
5
  * The Informatics Matters Account Server API.
@@ -8,6 +8,7 @@ A service that provides access to the Account Server, which gives *registered* u
8
8
 
9
9
  * OpenAPI spec version: 0.1
10
10
  */
11
+ import axios, { AxiosRequestConfig, AxiosResponse, AxiosError } from "axios";
11
12
  import {
12
13
  useQuery,
13
14
  useMutation,
@@ -27,7 +28,6 @@ import type {
27
28
  UnitsGetResponse,
28
29
  PersonalUnitPutResponse,
29
30
  } from "../account-server-api.schemas";
30
- import { customInstance, ErrorType } from ".././custom-instance";
31
31
 
32
32
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
33
33
  type AsyncReturnType<T extends (...args: any) => Promise<any>> = T extends (
@@ -36,61 +36,55 @@ type AsyncReturnType<T extends (...args: any) => Promise<any>> = T extends (
36
36
  ? R
37
37
  : any;
38
38
 
39
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
40
- type SecondParameter<T extends (...args: any) => any> = T extends (
41
- config: any,
42
- args: infer P
43
- ) => any
44
- ? P
45
- : never;
46
-
47
39
  /**
48
- * Gets Organisational Units you have access to
40
+ * Gets Organisational Units you have access to or that are public
49
41
 
50
42
  * @summary Gets Organisational Units
51
43
  */
52
- export const getOrganisationUnits = (
53
- orgid: string,
54
- options?: SecondParameter<typeof customInstance>
55
- ) => {
56
- return customInstance<OrganisationUnitsGetResponse>(
57
- { url: `/organisation/${orgid}/unit`, method: "get" },
58
- options
59
- );
44
+ export const appApiUnitGetOrgUnits = (
45
+ orgId: string,
46
+ options?: AxiosRequestConfig
47
+ ): Promise<AxiosResponse<OrganisationUnitsGetResponse>> => {
48
+ return axios.get(`/organisation/${orgId}/unit`, options);
60
49
  };
61
50
 
62
- export const getGetOrganisationUnitsQueryKey = (orgid: string) => [
63
- `/organisation/${orgid}/unit`,
51
+ export const getAppApiUnitGetOrgUnitsQueryKey = (orgId: string) => [
52
+ `/organisation/${orgId}/unit`,
64
53
  ];
65
54
 
66
- export const useGetOrganisationUnits = <
67
- TData = AsyncReturnType<typeof getOrganisationUnits>,
68
- TError = ErrorType<void | AsError>
55
+ export type AppApiUnitGetOrgUnitsQueryResult = NonNullable<
56
+ AsyncReturnType<typeof appApiUnitGetOrgUnits>
57
+ >;
58
+ export type AppApiUnitGetOrgUnitsQueryError = AxiosError<void | AsError>;
59
+
60
+ export const useAppApiUnitGetOrgUnits = <
61
+ TData = AsyncReturnType<typeof appApiUnitGetOrgUnits>,
62
+ TError = AxiosError<void | AsError>
69
63
  >(
70
- orgid: string,
64
+ orgId: string,
71
65
  options?: {
72
66
  query?: UseQueryOptions<
73
- AsyncReturnType<typeof getOrganisationUnits>,
67
+ AsyncReturnType<typeof appApiUnitGetOrgUnits>,
74
68
  TError,
75
69
  TData
76
70
  >;
77
- request?: SecondParameter<typeof customInstance>;
71
+ axios?: AxiosRequestConfig;
78
72
  }
79
73
  ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
80
- const { query: queryOptions, request: requestOptions } = options || {};
74
+ const { query: queryOptions, axios: axiosOptions } = options || {};
81
75
 
82
76
  const queryKey =
83
- queryOptions?.queryKey ?? getGetOrganisationUnitsQueryKey(orgid);
77
+ queryOptions?.queryKey ?? getAppApiUnitGetOrgUnitsQueryKey(orgId);
84
78
 
85
79
  const queryFn: QueryFunction<
86
- AsyncReturnType<typeof getOrganisationUnits>
87
- > = () => getOrganisationUnits(orgid, requestOptions);
80
+ AsyncReturnType<typeof appApiUnitGetOrgUnits>
81
+ > = () => appApiUnitGetOrgUnits(orgId, axiosOptions);
88
82
 
89
83
  const query = useQuery<
90
- AsyncReturnType<typeof getOrganisationUnits>,
84
+ AsyncReturnType<typeof appApiUnitGetOrgUnits>,
91
85
  TError,
92
86
  TData
93
- >(queryKey, queryFn, { enabled: !!orgid, ...queryOptions });
87
+ >(queryKey, queryFn, { enabled: !!orgId, ...queryOptions });
94
88
 
95
89
  return {
96
90
  queryKey,
@@ -103,94 +97,105 @@ export const useGetOrganisationUnits = <
103
97
 
104
98
  * @summary Create a new Organisational Unit
105
99
  */
106
- export const createOrganisationUnit = (
107
- orgid: string,
100
+ export const appApiUnitPost = (
101
+ orgId: string,
108
102
  organisationUnitPostBodyBody: OrganisationUnitPostBodyBody,
109
- options?: SecondParameter<typeof customInstance>
110
- ) => {
111
- return customInstance<OrganisationUnitPostResponse>(
112
- {
113
- url: `/organisation/${orgid}/unit`,
114
- method: "post",
115
- data: organisationUnitPostBodyBody,
116
- },
103
+ options?: AxiosRequestConfig
104
+ ): Promise<AxiosResponse<OrganisationUnitPostResponse>> => {
105
+ return axios.post(
106
+ `/organisation/${orgId}/unit`,
107
+ organisationUnitPostBodyBody,
117
108
  options
118
109
  );
119
110
  };
120
111
 
121
- export const useCreateOrganisationUnit = <
122
- TError = ErrorType<AsError | void>,
112
+ export type AppApiUnitPostMutationResult = NonNullable<
113
+ AsyncReturnType<typeof appApiUnitPost>
114
+ >;
115
+ export type AppApiUnitPostMutationBody = OrganisationUnitPostBodyBody;
116
+ export type AppApiUnitPostMutationError = AxiosError<AsError | void>;
117
+
118
+ export const useAppApiUnitPost = <
119
+ TError = AxiosError<AsError | void>,
123
120
  TContext = unknown
124
121
  >(options?: {
125
122
  mutation?: UseMutationOptions<
126
- AsyncReturnType<typeof createOrganisationUnit>,
123
+ AsyncReturnType<typeof appApiUnitPost>,
127
124
  TError,
128
- { orgid: string; data: OrganisationUnitPostBodyBody },
125
+ { orgId: string; data: OrganisationUnitPostBodyBody },
129
126
  TContext
130
127
  >;
131
- request?: SecondParameter<typeof customInstance>;
128
+ axios?: AxiosRequestConfig;
132
129
  }) => {
133
- const { mutation: mutationOptions, request: requestOptions } = options || {};
130
+ const { mutation: mutationOptions, axios: axiosOptions } = options || {};
134
131
 
135
132
  const mutationFn: MutationFunction<
136
- AsyncReturnType<typeof createOrganisationUnit>,
137
- { orgid: string; data: OrganisationUnitPostBodyBody }
133
+ AsyncReturnType<typeof appApiUnitPost>,
134
+ { orgId: string; data: OrganisationUnitPostBodyBody }
138
135
  > = (props) => {
139
- const { orgid, data } = props || {};
136
+ const { orgId, data } = props || {};
140
137
 
141
- return createOrganisationUnit(orgid, data, requestOptions);
138
+ return appApiUnitPost(orgId, data, axiosOptions);
142
139
  };
143
140
 
144
141
  return useMutation<
145
- AsyncReturnType<typeof createOrganisationUnit>,
142
+ AsyncReturnType<typeof appApiUnitPost>,
146
143
  TError,
147
- { orgid: string; data: OrganisationUnitPostBodyBody },
144
+ { orgId: string; data: OrganisationUnitPostBodyBody },
148
145
  TContext
149
146
  >(mutationFn, mutationOptions);
150
147
  };
151
148
  /**
152
- * Gets the Unit, assuming you are a member of it. Admin users can see all Units
149
+ * Gets the Unit, assuming you are a member of it or it is public. Admin users can see all Units
153
150
 
154
151
  * @summary Gets a Unit
155
152
  */
156
- export const getUnit = (
157
- orgid: string,
158
- unitid: string,
159
- options?: SecondParameter<typeof customInstance>
160
- ) => {
161
- return customInstance<UnitGetResponse>(
162
- { url: `/organisation/${orgid}/unit/${unitid}`, method: "get" },
163
- options
164
- );
153
+ export const appApiUnitGetUnit = (
154
+ orgId: string,
155
+ unitId: string,
156
+ options?: AxiosRequestConfig
157
+ ): Promise<AxiosResponse<UnitGetResponse>> => {
158
+ return axios.get(`/organisation/${orgId}/unit/${unitId}`, options);
165
159
  };
166
160
 
167
- export const getGetUnitQueryKey = (orgid: string, unitid: string) => [
168
- `/organisation/${orgid}/unit/${unitid}`,
161
+ export const getAppApiUnitGetUnitQueryKey = (orgId: string, unitId: string) => [
162
+ `/organisation/${orgId}/unit/${unitId}`,
169
163
  ];
170
164
 
171
- export const useGetUnit = <
172
- TData = AsyncReturnType<typeof getUnit>,
173
- TError = ErrorType<void | AsError>
165
+ export type AppApiUnitGetUnitQueryResult = NonNullable<
166
+ AsyncReturnType<typeof appApiUnitGetUnit>
167
+ >;
168
+ export type AppApiUnitGetUnitQueryError = AxiosError<void | AsError>;
169
+
170
+ export const useAppApiUnitGetUnit = <
171
+ TData = AsyncReturnType<typeof appApiUnitGetUnit>,
172
+ TError = AxiosError<void | AsError>
174
173
  >(
175
- orgid: string,
176
- unitid: string,
174
+ orgId: string,
175
+ unitId: string,
177
176
  options?: {
178
- query?: UseQueryOptions<AsyncReturnType<typeof getUnit>, TError, TData>;
179
- request?: SecondParameter<typeof customInstance>;
177
+ query?: UseQueryOptions<
178
+ AsyncReturnType<typeof appApiUnitGetUnit>,
179
+ TError,
180
+ TData
181
+ >;
182
+ axios?: AxiosRequestConfig;
180
183
  }
181
184
  ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
182
- const { query: queryOptions, request: requestOptions } = options || {};
185
+ const { query: queryOptions, axios: axiosOptions } = options || {};
183
186
 
184
- const queryKey = queryOptions?.queryKey ?? getGetUnitQueryKey(orgid, unitid);
187
+ const queryKey =
188
+ queryOptions?.queryKey ?? getAppApiUnitGetUnitQueryKey(orgId, unitId);
185
189
 
186
- const queryFn: QueryFunction<AsyncReturnType<typeof getUnit>> = () =>
187
- getUnit(orgid, unitid, requestOptions);
190
+ const queryFn: QueryFunction<
191
+ AsyncReturnType<typeof appApiUnitGetUnit>
192
+ > = () => appApiUnitGetUnit(orgId, unitId, axiosOptions);
188
193
 
189
- const query = useQuery<AsyncReturnType<typeof getUnit>, TError, TData>(
190
- queryKey,
191
- queryFn,
192
- { enabled: !!(orgid && unitid), ...queryOptions }
193
- );
194
+ const query = useQuery<
195
+ AsyncReturnType<typeof appApiUnitGetUnit>,
196
+ TError,
197
+ TData
198
+ >(queryKey, queryFn, { enabled: !!(orgId && unitId), ...queryOptions });
194
199
 
195
200
  return {
196
201
  queryKey,
@@ -203,76 +208,83 @@ export const useGetUnit = <
203
208
 
204
209
  * @summary Deletes an Organisational Unit
205
210
  */
206
- export const deleteOrganisationUnit = (
207
- orgid: string,
208
- unitid: string,
209
- options?: SecondParameter<typeof customInstance>
210
- ) => {
211
- return customInstance<void>(
212
- { url: `/organisation/${orgid}/unit/${unitid}`, method: "delete" },
213
- options
214
- );
211
+ export const appApiUnitDelete = (
212
+ orgId: string,
213
+ unitId: string,
214
+ options?: AxiosRequestConfig
215
+ ): Promise<AxiosResponse<void>> => {
216
+ return axios.delete(`/organisation/${orgId}/unit/${unitId}`, options);
215
217
  };
216
218
 
217
- export const useDeleteOrganisationUnit = <
218
- TError = ErrorType<AsError>,
219
+ export type AppApiUnitDeleteMutationResult = NonNullable<
220
+ AsyncReturnType<typeof appApiUnitDelete>
221
+ >;
222
+
223
+ export type AppApiUnitDeleteMutationError = AxiosError<AsError>;
224
+
225
+ export const useAppApiUnitDelete = <
226
+ TError = AxiosError<AsError>,
219
227
  TContext = unknown
220
228
  >(options?: {
221
229
  mutation?: UseMutationOptions<
222
- AsyncReturnType<typeof deleteOrganisationUnit>,
230
+ AsyncReturnType<typeof appApiUnitDelete>,
223
231
  TError,
224
- { orgid: string; unitid: string },
232
+ { orgId: string; unitId: string },
225
233
  TContext
226
234
  >;
227
- request?: SecondParameter<typeof customInstance>;
235
+ axios?: AxiosRequestConfig;
228
236
  }) => {
229
- const { mutation: mutationOptions, request: requestOptions } = options || {};
237
+ const { mutation: mutationOptions, axios: axiosOptions } = options || {};
230
238
 
231
239
  const mutationFn: MutationFunction<
232
- AsyncReturnType<typeof deleteOrganisationUnit>,
233
- { orgid: string; unitid: string }
240
+ AsyncReturnType<typeof appApiUnitDelete>,
241
+ { orgId: string; unitId: string }
234
242
  > = (props) => {
235
- const { orgid, unitid } = props || {};
243
+ const { orgId, unitId } = props || {};
236
244
 
237
- return deleteOrganisationUnit(orgid, unitid, requestOptions);
245
+ return appApiUnitDelete(orgId, unitId, axiosOptions);
238
246
  };
239
247
 
240
248
  return useMutation<
241
- AsyncReturnType<typeof deleteOrganisationUnit>,
249
+ AsyncReturnType<typeof appApiUnitDelete>,
242
250
  TError,
243
- { orgid: string; unitid: string },
251
+ { orgId: string; unitId: string },
244
252
  TContext
245
253
  >(mutationFn, mutationOptions);
246
254
  };
247
255
  /**
248
- * Gets all the Units you are a member of. Admin users can see all Units
256
+ * Gets all the Units that are public or you are a member of. Admin users can see all Units
249
257
 
250
- * @summary Gets Units a User has access to
258
+ * @summary Gets Units
251
259
  */
252
- export const getUnits = (options?: SecondParameter<typeof customInstance>) => {
253
- return customInstance<UnitsGetResponse>(
254
- { url: `/unit`, method: "get" },
255
- options
256
- );
260
+ export const appApiUnitGet = (
261
+ options?: AxiosRequestConfig
262
+ ): Promise<AxiosResponse<UnitsGetResponse>> => {
263
+ return axios.get(`/unit`, options);
257
264
  };
258
265
 
259
- export const getGetUnitsQueryKey = () => [`/unit`];
266
+ export const getAppApiUnitGetQueryKey = () => [`/unit`];
267
+
268
+ export type AppApiUnitGetQueryResult = NonNullable<
269
+ AsyncReturnType<typeof appApiUnitGet>
270
+ >;
271
+ export type AppApiUnitGetQueryError = AxiosError<void | AsError>;
260
272
 
261
- export const useGetUnits = <
262
- TData = AsyncReturnType<typeof getUnits>,
263
- TError = ErrorType<void | AsError>
273
+ export const useAppApiUnitGet = <
274
+ TData = AsyncReturnType<typeof appApiUnitGet>,
275
+ TError = AxiosError<void | AsError>
264
276
  >(options?: {
265
- query?: UseQueryOptions<AsyncReturnType<typeof getUnits>, TError, TData>;
266
- request?: SecondParameter<typeof customInstance>;
277
+ query?: UseQueryOptions<AsyncReturnType<typeof appApiUnitGet>, TError, TData>;
278
+ axios?: AxiosRequestConfig;
267
279
  }): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {
268
- const { query: queryOptions, request: requestOptions } = options || {};
280
+ const { query: queryOptions, axios: axiosOptions } = options || {};
269
281
 
270
- const queryKey = queryOptions?.queryKey ?? getGetUnitsQueryKey();
282
+ const queryKey = queryOptions?.queryKey ?? getAppApiUnitGetQueryKey();
271
283
 
272
- const queryFn: QueryFunction<AsyncReturnType<typeof getUnits>> = () =>
273
- getUnits(requestOptions);
284
+ const queryFn: QueryFunction<AsyncReturnType<typeof appApiUnitGet>> = () =>
285
+ appApiUnitGet(axiosOptions);
274
286
 
275
- const query = useQuery<AsyncReturnType<typeof getUnits>, TError, TData>(
287
+ const query = useQuery<AsyncReturnType<typeof appApiUnitGet>, TError, TData>(
276
288
  queryKey,
277
289
  queryFn,
278
290
  queryOptions
@@ -289,39 +301,42 @@ export const useGetUnits = <
289
301
 
290
302
  * @summary Create a new Independent User Unit
291
303
  */
292
- export const createDefaultUnit = (
293
- options?: SecondParameter<typeof customInstance>
294
- ) => {
295
- return customInstance<PersonalUnitPutResponse>(
296
- { url: `/unit`, method: "put" },
297
- options
298
- );
304
+ export const appApiUnitPersonalPut = (
305
+ options?: AxiosRequestConfig
306
+ ): Promise<AxiosResponse<PersonalUnitPutResponse>> => {
307
+ return axios.put(`/unit`, undefined, options);
299
308
  };
300
309
 
301
- export const useCreateDefaultUnit = <
302
- TError = ErrorType<AsError | void>,
310
+ export type AppApiUnitPersonalPutMutationResult = NonNullable<
311
+ AsyncReturnType<typeof appApiUnitPersonalPut>
312
+ >;
313
+
314
+ export type AppApiUnitPersonalPutMutationError = AxiosError<AsError | void>;
315
+
316
+ export const useAppApiUnitPersonalPut = <
317
+ TError = AxiosError<AsError | void>,
303
318
  TVariables = void,
304
319
  TContext = unknown
305
320
  >(options?: {
306
321
  mutation?: UseMutationOptions<
307
- AsyncReturnType<typeof createDefaultUnit>,
322
+ AsyncReturnType<typeof appApiUnitPersonalPut>,
308
323
  TError,
309
324
  TVariables,
310
325
  TContext
311
326
  >;
312
- request?: SecondParameter<typeof customInstance>;
327
+ axios?: AxiosRequestConfig;
313
328
  }) => {
314
- const { mutation: mutationOptions, request: requestOptions } = options || {};
329
+ const { mutation: mutationOptions, axios: axiosOptions } = options || {};
315
330
 
316
331
  const mutationFn: MutationFunction<
317
- AsyncReturnType<typeof createDefaultUnit>,
332
+ AsyncReturnType<typeof appApiUnitPersonalPut>,
318
333
  TVariables
319
334
  > = () => {
320
- return createDefaultUnit(requestOptions);
335
+ return appApiUnitPersonalPut(axiosOptions);
321
336
  };
322
337
 
323
338
  return useMutation<
324
- AsyncReturnType<typeof createDefaultUnit>,
339
+ AsyncReturnType<typeof appApiUnitPersonalPut>,
325
340
  TError,
326
341
  TVariables,
327
342
  TContext
@@ -332,36 +347,42 @@ export const useCreateDefaultUnit = <
332
347
 
333
348
  * @summary Deletes an Independent Unit
334
349
  */
335
- export const deleteDefaultUnit = (
336
- options?: SecondParameter<typeof customInstance>
337
- ) => {
338
- return customInstance<void>({ url: `/unit`, method: "delete" }, options);
350
+ export const appApiUnitPersonalDelete = (
351
+ options?: AxiosRequestConfig
352
+ ): Promise<AxiosResponse<void>> => {
353
+ return axios.delete(`/unit`, options);
339
354
  };
340
355
 
341
- export const useDeleteDefaultUnit = <
342
- TError = ErrorType<AsError>,
356
+ export type AppApiUnitPersonalDeleteMutationResult = NonNullable<
357
+ AsyncReturnType<typeof appApiUnitPersonalDelete>
358
+ >;
359
+
360
+ export type AppApiUnitPersonalDeleteMutationError = AxiosError<AsError>;
361
+
362
+ export const useAppApiUnitPersonalDelete = <
363
+ TError = AxiosError<AsError>,
343
364
  TVariables = void,
344
365
  TContext = unknown
345
366
  >(options?: {
346
367
  mutation?: UseMutationOptions<
347
- AsyncReturnType<typeof deleteDefaultUnit>,
368
+ AsyncReturnType<typeof appApiUnitPersonalDelete>,
348
369
  TError,
349
370
  TVariables,
350
371
  TContext
351
372
  >;
352
- request?: SecondParameter<typeof customInstance>;
373
+ axios?: AxiosRequestConfig;
353
374
  }) => {
354
- const { mutation: mutationOptions, request: requestOptions } = options || {};
375
+ const { mutation: mutationOptions, axios: axiosOptions } = options || {};
355
376
 
356
377
  const mutationFn: MutationFunction<
357
- AsyncReturnType<typeof deleteDefaultUnit>,
378
+ AsyncReturnType<typeof appApiUnitPersonalDelete>,
358
379
  TVariables
359
380
  > = () => {
360
- return deleteDefaultUnit(requestOptions);
381
+ return appApiUnitPersonalDelete(axiosOptions);
361
382
  };
362
383
 
363
384
  return useMutation<
364
- AsyncReturnType<typeof deleteDefaultUnit>,
385
+ AsyncReturnType<typeof appApiUnitPersonalDelete>,
365
386
  TError,
366
387
  TVariables,
367
388
  TContext