@squonk/account-server-client 2.1.0-rc.8 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/admin/admin.cjs +19 -4
- package/admin/admin.cjs.map +1 -1
- package/admin/admin.d.cts +23 -6
- package/admin/admin.d.ts +23 -6
- package/admin/admin.js +19 -4
- package/admin/admin.js.map +1 -1
- package/asset/asset.cjs +33 -18
- package/asset/asset.cjs.map +1 -1
- package/asset/asset.d.cts +31 -14
- package/asset/asset.d.ts +31 -14
- package/asset/asset.js +25 -10
- package/asset/asset.js.map +1 -1
- package/{chunk-UKA7G3OB.js → chunk-EBOQPVLG.js} +2 -2
- package/{chunk-UKA7G3OB.js.map → chunk-EBOQPVLG.js.map} +1 -1
- package/{chunk-J22A7LHX.cjs → chunk-TKLTUR4R.cjs} +2 -2
- package/chunk-TKLTUR4R.cjs.map +1 -0
- package/event-stream/event-stream.cjs +39 -10
- package/event-stream/event-stream.cjs.map +1 -1
- package/event-stream/event-stream.d.cts +51 -17
- package/event-stream/event-stream.d.ts +51 -17
- package/event-stream/event-stream.js +36 -7
- package/event-stream/event-stream.js.map +1 -1
- package/index.cjs +2 -2
- package/index.cjs.map +1 -1
- package/index.d.cts +702 -2
- package/index.d.ts +702 -2
- package/index.js +1 -1
- package/index.js.map +1 -1
- package/merchant/merchant.cjs +35 -6
- package/merchant/merchant.cjs.map +1 -1
- package/merchant/merchant.d.cts +42 -8
- package/merchant/merchant.d.ts +42 -8
- package/merchant/merchant.js +34 -5
- package/merchant/merchant.js.map +1 -1
- package/organisation/organisation.cjs +73 -16
- package/organisation/organisation.cjs.map +1 -1
- package/organisation/organisation.d.cts +84 -16
- package/organisation/organisation.d.ts +84 -16
- package/organisation/organisation.js +66 -9
- package/organisation/organisation.js.map +1 -1
- package/package.json +12 -12
- package/product/product.cjs +121 -22
- package/product/product.cjs.map +1 -1
- package/product/product.d.cts +141 -22
- package/product/product.d.ts +141 -22
- package/product/product.js +111 -12
- package/product/product.js.map +1 -1
- package/src/account-server-api.schemas.ts +4 -2
- package/src/admin/admin.ts +50 -14
- package/src/asset/asset.ts +57 -35
- package/src/custom-instance.ts +3 -4
- package/src/event-stream/event-stream.ts +100 -29
- package/src/merchant/merchant.ts +93 -18
- package/src/organisation/organisation.ts +184 -35
- package/src/product/product.ts +313 -47
- package/src/state/state.ts +50 -14
- package/src/unit/unit.ts +190 -45
- package/src/user/user.ts +140 -34
- package/state/state.cjs +19 -4
- package/state/state.cjs.map +1 -1
- package/state/state.d.cts +23 -6
- package/state/state.d.ts +23 -6
- package/state/state.js +19 -4
- package/state/state.js.map +1 -1
- package/unit/unit.cjs +77 -20
- package/unit/unit.cjs.map +1 -1
- package/unit/unit.d.cts +91 -23
- package/unit/unit.d.ts +91 -23
- package/unit/unit.js +68 -11
- package/unit/unit.js.map +1 -1
- package/user/user.cjs +59 -16
- package/user/user.cjs.map +1 -1
- package/user/user.d.cts +66 -15
- package/user/user.d.ts +66 -15
- package/user/user.js +53 -10
- package/user/user.js.map +1 -1
- package/chunk-J22A7LHX.cjs.map +0 -1
- package/custom-instance-6780910b.d.ts +0 -700
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import { UseQueryOptions, QueryKey, UseQueryResult, UseMutationOptions } from '@tanstack/react-query';
|
|
3
|
-
import {
|
|
1
|
+
import * as _tanstack_react_query_build_legacy_types from '@tanstack/react-query/build/legacy/types';
|
|
2
|
+
import { UseQueryOptions, QueryKey, UseQueryResult, UseSuspenseQueryOptions, UseSuspenseQueryResult, UseMutationOptions } from '@tanstack/react-query';
|
|
3
|
+
import { customInstance, OrganisationsGetResponse, ErrorType, AsError, OrganisationPostBodyBody, OrganisationPostResponse, OrganisationDetail, OrganisationPatchBodyBody, GetOrganisationChargesParams, OrganisationChargesGetResponse, OrganisationGetDefaultResponse } from '../index.js';
|
|
4
4
|
import 'axios';
|
|
5
5
|
|
|
6
|
-
type SecondParameter<T extends (...args: any) => any> = T
|
|
6
|
+
type SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];
|
|
7
7
|
/**
|
|
8
8
|
* Gets all the Organisations that you are a member of or are public. Admin users are members of all Organisations
|
|
9
9
|
|
|
@@ -12,7 +12,7 @@ type SecondParameter<T extends (...args: any) => any> = T extends (config: any,
|
|
|
12
12
|
declare const getOrganisations: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationsGetResponse>;
|
|
13
13
|
declare const getGetOrganisationsQueryKey: () => readonly ["account-server-api", "/organisation"];
|
|
14
14
|
declare const getGetOrganisationsQueryOptions: <TData = OrganisationsGetResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
15
|
-
query?: UseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey
|
|
15
|
+
query?: Partial<UseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey>> | undefined;
|
|
16
16
|
request?: SecondParameter<typeof customInstance>;
|
|
17
17
|
} | undefined) => UseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey> & {
|
|
18
18
|
queryKey: QueryKey;
|
|
@@ -23,11 +23,28 @@ type GetOrganisationsQueryError = ErrorType<void | AsError>;
|
|
|
23
23
|
* @summary Gets Organisations
|
|
24
24
|
*/
|
|
25
25
|
declare const useGetOrganisations: <TData = OrganisationsGetResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
26
|
-
query?: UseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey
|
|
26
|
+
query?: Partial<UseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey>> | undefined;
|
|
27
27
|
request?: SecondParameter<typeof customInstance>;
|
|
28
28
|
} | undefined) => UseQueryResult<TData, TError> & {
|
|
29
29
|
queryKey: QueryKey;
|
|
30
30
|
};
|
|
31
|
+
declare const getGetOrganisationsSuspenseQueryOptions: <TData = OrganisationsGetResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
32
|
+
query?: Partial<UseSuspenseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey>> | undefined;
|
|
33
|
+
request?: SecondParameter<typeof customInstance>;
|
|
34
|
+
} | undefined) => UseSuspenseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey> & {
|
|
35
|
+
queryKey: QueryKey;
|
|
36
|
+
};
|
|
37
|
+
type GetOrganisationsSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>;
|
|
38
|
+
type GetOrganisationsSuspenseQueryError = ErrorType<void | AsError>;
|
|
39
|
+
/**
|
|
40
|
+
* @summary Gets Organisations
|
|
41
|
+
*/
|
|
42
|
+
declare const useGetOrganisationsSuspense: <TData = OrganisationsGetResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
43
|
+
query?: Partial<UseSuspenseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey>> | undefined;
|
|
44
|
+
request?: SecondParameter<typeof customInstance>;
|
|
45
|
+
} | undefined) => UseSuspenseQueryResult<TData, TError> & {
|
|
46
|
+
queryKey: QueryKey;
|
|
47
|
+
};
|
|
31
48
|
/**
|
|
32
49
|
* Creates a new Organisation
|
|
33
50
|
|
|
@@ -55,7 +72,7 @@ declare const useCreateOrganisation: <TError = ErrorType<void | AsError>, TConte
|
|
|
55
72
|
data: OrganisationPostBodyBody;
|
|
56
73
|
}, TContext> | undefined;
|
|
57
74
|
request?: SecondParameter<typeof customInstance>;
|
|
58
|
-
} | undefined) =>
|
|
75
|
+
} | undefined) => _tanstack_react_query_build_legacy_types.UseMutationResult<OrganisationPostResponse, TError, {
|
|
59
76
|
data: OrganisationPostBodyBody;
|
|
60
77
|
}, TContext>;
|
|
61
78
|
/**
|
|
@@ -68,7 +85,7 @@ Members of an Organisation's **Unit** do not necessarily have access to the Orga
|
|
|
68
85
|
declare const getOrganisation: (orgId: string, options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationDetail>;
|
|
69
86
|
declare const getGetOrganisationQueryKey: (orgId: string) => readonly ["account-server-api", `/organisation/${string}`];
|
|
70
87
|
declare const getGetOrganisationQueryOptions: <TData = OrganisationDetail, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
71
|
-
query?: UseQueryOptions<OrganisationDetail, TError, TData, QueryKey
|
|
88
|
+
query?: Partial<UseQueryOptions<OrganisationDetail, TError, TData, QueryKey>> | undefined;
|
|
72
89
|
request?: SecondParameter<typeof customInstance>;
|
|
73
90
|
} | undefined) => UseQueryOptions<OrganisationDetail, TError, TData, QueryKey> & {
|
|
74
91
|
queryKey: QueryKey;
|
|
@@ -79,11 +96,28 @@ type GetOrganisationQueryError = ErrorType<void | AsError>;
|
|
|
79
96
|
* @summary Gets an Organisation
|
|
80
97
|
*/
|
|
81
98
|
declare const useGetOrganisation: <TData = OrganisationDetail, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
82
|
-
query?: UseQueryOptions<OrganisationDetail, TError, TData, QueryKey
|
|
99
|
+
query?: Partial<UseQueryOptions<OrganisationDetail, TError, TData, QueryKey>> | undefined;
|
|
83
100
|
request?: SecondParameter<typeof customInstance>;
|
|
84
101
|
} | undefined) => UseQueryResult<TData, TError> & {
|
|
85
102
|
queryKey: QueryKey;
|
|
86
103
|
};
|
|
104
|
+
declare const getGetOrganisationSuspenseQueryOptions: <TData = OrganisationDetail, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
105
|
+
query?: Partial<UseSuspenseQueryOptions<OrganisationDetail, TError, TData, QueryKey>> | undefined;
|
|
106
|
+
request?: SecondParameter<typeof customInstance>;
|
|
107
|
+
} | undefined) => UseSuspenseQueryOptions<OrganisationDetail, TError, TData, QueryKey> & {
|
|
108
|
+
queryKey: QueryKey;
|
|
109
|
+
};
|
|
110
|
+
type GetOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>;
|
|
111
|
+
type GetOrganisationSuspenseQueryError = ErrorType<void | AsError>;
|
|
112
|
+
/**
|
|
113
|
+
* @summary Gets an Organisation
|
|
114
|
+
*/
|
|
115
|
+
declare const useGetOrganisationSuspense: <TData = OrganisationDetail, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
116
|
+
query?: Partial<UseSuspenseQueryOptions<OrganisationDetail, TError, TData, QueryKey>> | undefined;
|
|
117
|
+
request?: SecondParameter<typeof customInstance>;
|
|
118
|
+
} | undefined) => UseSuspenseQueryResult<TData, TError> & {
|
|
119
|
+
queryKey: QueryKey;
|
|
120
|
+
};
|
|
87
121
|
/**
|
|
88
122
|
* Used to update existing Organisation.
|
|
89
123
|
|
|
@@ -114,7 +148,7 @@ declare const usePatchOrganisation: <TError = ErrorType<AsError>, TContext = unk
|
|
|
114
148
|
data: OrganisationPatchBodyBody;
|
|
115
149
|
}, TContext> | undefined;
|
|
116
150
|
request?: SecondParameter<typeof customInstance>;
|
|
117
|
-
} | undefined) =>
|
|
151
|
+
} | undefined) => _tanstack_react_query_build_legacy_types.UseMutationResult<void, TError, {
|
|
118
152
|
orgId: string;
|
|
119
153
|
data: OrganisationPatchBodyBody;
|
|
120
154
|
}, TContext>;
|
|
@@ -144,7 +178,7 @@ declare const useDeleteOrganisation: <TError = ErrorType<AsError>, TContext = un
|
|
|
144
178
|
orgId: string;
|
|
145
179
|
}, TContext> | undefined;
|
|
146
180
|
request?: SecondParameter<typeof customInstance>;
|
|
147
|
-
} | undefined) =>
|
|
181
|
+
} | undefined) => _tanstack_react_query_build_legacy_types.UseMutationResult<void, TError, {
|
|
148
182
|
orgId: string;
|
|
149
183
|
}, TContext>;
|
|
150
184
|
/**
|
|
@@ -157,7 +191,7 @@ The Organisation cannot be the **Default Organisation** and you need to be a mem
|
|
|
157
191
|
declare const getOrganisationCharges: (orgId: string, params?: GetOrganisationChargesParams, options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationChargesGetResponse>;
|
|
158
192
|
declare const getGetOrganisationChargesQueryKey: (orgId: string, params?: GetOrganisationChargesParams) => readonly ["account-server-api", `/organisation/${string}/charges`, ...GetOrganisationChargesParams[]];
|
|
159
193
|
declare const getGetOrganisationChargesQueryOptions: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
|
|
160
|
-
query?: UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey
|
|
194
|
+
query?: Partial<UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
|
|
161
195
|
request?: SecondParameter<typeof customInstance>;
|
|
162
196
|
} | undefined) => UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey> & {
|
|
163
197
|
queryKey: QueryKey;
|
|
@@ -168,11 +202,28 @@ type GetOrganisationChargesQueryError = ErrorType<void | AsError>;
|
|
|
168
202
|
* @summary Gets charges for all Units in an Organisation
|
|
169
203
|
*/
|
|
170
204
|
declare const useGetOrganisationCharges: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
|
|
171
|
-
query?: UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey
|
|
205
|
+
query?: Partial<UseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
|
|
172
206
|
request?: SecondParameter<typeof customInstance>;
|
|
173
207
|
} | undefined) => UseQueryResult<TData, TError> & {
|
|
174
208
|
queryKey: QueryKey;
|
|
175
209
|
};
|
|
210
|
+
declare const getGetOrganisationChargesSuspenseQueryOptions: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
|
|
211
|
+
query?: Partial<UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
|
|
212
|
+
request?: SecondParameter<typeof customInstance>;
|
|
213
|
+
} | undefined) => UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey> & {
|
|
214
|
+
queryKey: QueryKey;
|
|
215
|
+
};
|
|
216
|
+
type GetOrganisationChargesSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>;
|
|
217
|
+
type GetOrganisationChargesSuspenseQueryError = ErrorType<void | AsError>;
|
|
218
|
+
/**
|
|
219
|
+
* @summary Gets charges for all Units in an Organisation
|
|
220
|
+
*/
|
|
221
|
+
declare const useGetOrganisationChargesSuspense: <TData = OrganisationChargesGetResponse, TError = ErrorType<void | AsError>>(orgId: string, params?: GetOrganisationChargesParams, options?: {
|
|
222
|
+
query?: Partial<UseSuspenseQueryOptions<OrganisationChargesGetResponse, TError, TData, QueryKey>> | undefined;
|
|
223
|
+
request?: SecondParameter<typeof customInstance>;
|
|
224
|
+
} | undefined) => UseSuspenseQueryResult<TData, TError> & {
|
|
225
|
+
queryKey: QueryKey;
|
|
226
|
+
};
|
|
176
227
|
/**
|
|
177
228
|
* Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.
|
|
178
229
|
|
|
@@ -183,7 +234,7 @@ Any authorised user can see the Default Organisation.
|
|
|
183
234
|
declare const getDefaultOrganisation: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationGetDefaultResponse>;
|
|
184
235
|
declare const getGetDefaultOrganisationQueryKey: () => readonly ["account-server-api", "/organisation/default"];
|
|
185
236
|
declare const getGetDefaultOrganisationQueryOptions: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
186
|
-
query?: UseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey
|
|
237
|
+
query?: Partial<UseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey>> | undefined;
|
|
187
238
|
request?: SecondParameter<typeof customInstance>;
|
|
188
239
|
} | undefined) => UseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey> & {
|
|
189
240
|
queryKey: QueryKey;
|
|
@@ -194,10 +245,27 @@ type GetDefaultOrganisationQueryError = ErrorType<void | AsError>;
|
|
|
194
245
|
* @summary Gets the Default Organisation
|
|
195
246
|
*/
|
|
196
247
|
declare const useGetDefaultOrganisation: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
197
|
-
query?: UseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey
|
|
248
|
+
query?: Partial<UseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey>> | undefined;
|
|
198
249
|
request?: SecondParameter<typeof customInstance>;
|
|
199
250
|
} | undefined) => UseQueryResult<TData, TError> & {
|
|
200
251
|
queryKey: QueryKey;
|
|
201
252
|
};
|
|
253
|
+
declare const getGetDefaultOrganisationSuspenseQueryOptions: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
254
|
+
query?: Partial<UseSuspenseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey>> | undefined;
|
|
255
|
+
request?: SecondParameter<typeof customInstance>;
|
|
256
|
+
} | undefined) => UseSuspenseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey> & {
|
|
257
|
+
queryKey: QueryKey;
|
|
258
|
+
};
|
|
259
|
+
type GetDefaultOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>;
|
|
260
|
+
type GetDefaultOrganisationSuspenseQueryError = ErrorType<void | AsError>;
|
|
261
|
+
/**
|
|
262
|
+
* @summary Gets the Default Organisation
|
|
263
|
+
*/
|
|
264
|
+
declare const useGetDefaultOrganisationSuspense: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
265
|
+
query?: Partial<UseSuspenseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey>> | undefined;
|
|
266
|
+
request?: SecondParameter<typeof customInstance>;
|
|
267
|
+
} | undefined) => UseSuspenseQueryResult<TData, TError> & {
|
|
268
|
+
queryKey: QueryKey;
|
|
269
|
+
};
|
|
202
270
|
|
|
203
|
-
export { CreateOrganisationMutationBody, CreateOrganisationMutationError, CreateOrganisationMutationResult, DeleteOrganisationMutationError, DeleteOrganisationMutationResult, GetDefaultOrganisationQueryError, GetDefaultOrganisationQueryResult, GetOrganisationChargesQueryError, GetOrganisationChargesQueryResult, GetOrganisationQueryError, GetOrganisationQueryResult, GetOrganisationsQueryError, GetOrganisationsQueryResult, PatchOrganisationMutationBody, PatchOrganisationMutationError, PatchOrganisationMutationResult, createOrganisation, deleteOrganisation, getCreateOrganisationMutationOptions, getDefaultOrganisation, getDeleteOrganisationMutationOptions, getGetDefaultOrganisationQueryKey, getGetDefaultOrganisationQueryOptions, getGetOrganisationChargesQueryKey, getGetOrganisationChargesQueryOptions, getGetOrganisationQueryKey, getGetOrganisationQueryOptions, getGetOrganisationsQueryKey, getGetOrganisationsQueryOptions, getOrganisation, getOrganisationCharges, getOrganisations, getPatchOrganisationMutationOptions, patchOrganisation, useCreateOrganisation, useDeleteOrganisation, useGetDefaultOrganisation, useGetOrganisation, useGetOrganisationCharges, useGetOrganisations, usePatchOrganisation };
|
|
271
|
+
export { type CreateOrganisationMutationBody, type CreateOrganisationMutationError, type CreateOrganisationMutationResult, type DeleteOrganisationMutationError, type DeleteOrganisationMutationResult, type GetDefaultOrganisationQueryError, type GetDefaultOrganisationQueryResult, type GetDefaultOrganisationSuspenseQueryError, type GetDefaultOrganisationSuspenseQueryResult, type GetOrganisationChargesQueryError, type GetOrganisationChargesQueryResult, type GetOrganisationChargesSuspenseQueryError, type GetOrganisationChargesSuspenseQueryResult, type GetOrganisationQueryError, type GetOrganisationQueryResult, type GetOrganisationSuspenseQueryError, type GetOrganisationSuspenseQueryResult, type GetOrganisationsQueryError, type GetOrganisationsQueryResult, type GetOrganisationsSuspenseQueryError, type GetOrganisationsSuspenseQueryResult, type PatchOrganisationMutationBody, type PatchOrganisationMutationError, type PatchOrganisationMutationResult, createOrganisation, deleteOrganisation, getCreateOrganisationMutationOptions, getDefaultOrganisation, getDeleteOrganisationMutationOptions, getGetDefaultOrganisationQueryKey, getGetDefaultOrganisationQueryOptions, getGetDefaultOrganisationSuspenseQueryOptions, getGetOrganisationChargesQueryKey, getGetOrganisationChargesQueryOptions, getGetOrganisationChargesSuspenseQueryOptions, getGetOrganisationQueryKey, getGetOrganisationQueryOptions, getGetOrganisationSuspenseQueryOptions, getGetOrganisationsQueryKey, getGetOrganisationsQueryOptions, getGetOrganisationsSuspenseQueryOptions, getOrganisation, getOrganisationCharges, getOrganisations, getPatchOrganisationMutationOptions, patchOrganisation, useCreateOrganisation, useDeleteOrganisation, useGetDefaultOrganisation, useGetDefaultOrganisationSuspense, useGetOrganisation, useGetOrganisationCharges, useGetOrganisationChargesSuspense, useGetOrganisationSuspense, useGetOrganisations, useGetOrganisationsSuspense, usePatchOrganisation };
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
customInstance
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-EBOQPVLG.js";
|
|
4
4
|
|
|
5
5
|
// src/organisation/organisation.ts
|
|
6
6
|
import {
|
|
7
7
|
useMutation,
|
|
8
|
-
useQuery
|
|
8
|
+
useQuery,
|
|
9
|
+
useSuspenseQuery
|
|
9
10
|
} from "@tanstack/react-query";
|
|
10
11
|
var getOrganisations = (options, signal) => {
|
|
11
12
|
return customInstance(
|
|
12
13
|
{
|
|
13
14
|
url: `/organisation`,
|
|
14
|
-
method: "
|
|
15
|
+
method: "GET",
|
|
15
16
|
signal
|
|
16
17
|
},
|
|
17
18
|
options
|
|
@@ -32,11 +33,23 @@ var useGetOrganisations = (options) => {
|
|
|
32
33
|
query.queryKey = queryOptions.queryKey;
|
|
33
34
|
return query;
|
|
34
35
|
};
|
|
36
|
+
var getGetOrganisationsSuspenseQueryOptions = (options) => {
|
|
37
|
+
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
38
|
+
const queryKey = (queryOptions == null ? void 0 : queryOptions.queryKey) ?? getGetOrganisationsQueryKey();
|
|
39
|
+
const queryFn = ({ signal }) => getOrganisations(requestOptions, signal);
|
|
40
|
+
return { queryKey, queryFn, ...queryOptions };
|
|
41
|
+
};
|
|
42
|
+
var useGetOrganisationsSuspense = (options) => {
|
|
43
|
+
const queryOptions = getGetOrganisationsSuspenseQueryOptions(options);
|
|
44
|
+
const query = useSuspenseQuery(queryOptions);
|
|
45
|
+
query.queryKey = queryOptions.queryKey;
|
|
46
|
+
return query;
|
|
47
|
+
};
|
|
35
48
|
var createOrganisation = (organisationPostBodyBody, options) => {
|
|
36
49
|
return customInstance(
|
|
37
50
|
{
|
|
38
51
|
url: `/organisation`,
|
|
39
|
-
method: "
|
|
52
|
+
method: "POST",
|
|
40
53
|
headers: { "Content-Type": "application/json" },
|
|
41
54
|
data: organisationPostBodyBody
|
|
42
55
|
},
|
|
@@ -59,7 +72,7 @@ var getOrganisation = (orgId, options, signal) => {
|
|
|
59
72
|
return customInstance(
|
|
60
73
|
{
|
|
61
74
|
url: `/organisation/${orgId}`,
|
|
62
|
-
method: "
|
|
75
|
+
method: "GET",
|
|
63
76
|
signal
|
|
64
77
|
},
|
|
65
78
|
options
|
|
@@ -80,11 +93,23 @@ var useGetOrganisation = (orgId, options) => {
|
|
|
80
93
|
query.queryKey = queryOptions.queryKey;
|
|
81
94
|
return query;
|
|
82
95
|
};
|
|
96
|
+
var getGetOrganisationSuspenseQueryOptions = (orgId, options) => {
|
|
97
|
+
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
98
|
+
const queryKey = (queryOptions == null ? void 0 : queryOptions.queryKey) ?? getGetOrganisationQueryKey(orgId);
|
|
99
|
+
const queryFn = ({ signal }) => getOrganisation(orgId, requestOptions, signal);
|
|
100
|
+
return { queryKey, queryFn, enabled: !!orgId, ...queryOptions };
|
|
101
|
+
};
|
|
102
|
+
var useGetOrganisationSuspense = (orgId, options) => {
|
|
103
|
+
const queryOptions = getGetOrganisationSuspenseQueryOptions(orgId, options);
|
|
104
|
+
const query = useSuspenseQuery(queryOptions);
|
|
105
|
+
query.queryKey = queryOptions.queryKey;
|
|
106
|
+
return query;
|
|
107
|
+
};
|
|
83
108
|
var patchOrganisation = (orgId, organisationPatchBodyBody, options) => {
|
|
84
109
|
return customInstance(
|
|
85
110
|
{
|
|
86
111
|
url: `/organisation/${orgId}`,
|
|
87
|
-
method: "
|
|
112
|
+
method: "PATCH",
|
|
88
113
|
headers: { "Content-Type": "application/json" },
|
|
89
114
|
data: organisationPatchBodyBody
|
|
90
115
|
},
|
|
@@ -107,7 +132,7 @@ var deleteOrganisation = (orgId, options) => {
|
|
|
107
132
|
return customInstance(
|
|
108
133
|
{
|
|
109
134
|
url: `/organisation/${orgId}`,
|
|
110
|
-
method: "
|
|
135
|
+
method: "DELETE"
|
|
111
136
|
},
|
|
112
137
|
options
|
|
113
138
|
);
|
|
@@ -128,7 +153,7 @@ var getOrganisationCharges = (orgId, params, options, signal) => {
|
|
|
128
153
|
return customInstance(
|
|
129
154
|
{
|
|
130
155
|
url: `/organisation/${orgId}/charges`,
|
|
131
|
-
method: "
|
|
156
|
+
method: "GET",
|
|
132
157
|
params,
|
|
133
158
|
signal
|
|
134
159
|
},
|
|
@@ -150,11 +175,23 @@ var useGetOrganisationCharges = (orgId, params, options) => {
|
|
|
150
175
|
query.queryKey = queryOptions.queryKey;
|
|
151
176
|
return query;
|
|
152
177
|
};
|
|
178
|
+
var getGetOrganisationChargesSuspenseQueryOptions = (orgId, params, options) => {
|
|
179
|
+
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
180
|
+
const queryKey = (queryOptions == null ? void 0 : queryOptions.queryKey) ?? getGetOrganisationChargesQueryKey(orgId, params);
|
|
181
|
+
const queryFn = ({ signal }) => getOrganisationCharges(orgId, params, requestOptions, signal);
|
|
182
|
+
return { queryKey, queryFn, enabled: !!orgId, ...queryOptions };
|
|
183
|
+
};
|
|
184
|
+
var useGetOrganisationChargesSuspense = (orgId, params, options) => {
|
|
185
|
+
const queryOptions = getGetOrganisationChargesSuspenseQueryOptions(orgId, params, options);
|
|
186
|
+
const query = useSuspenseQuery(queryOptions);
|
|
187
|
+
query.queryKey = queryOptions.queryKey;
|
|
188
|
+
return query;
|
|
189
|
+
};
|
|
153
190
|
var getDefaultOrganisation = (options, signal) => {
|
|
154
191
|
return customInstance(
|
|
155
192
|
{
|
|
156
193
|
url: `/organisation/default`,
|
|
157
|
-
method: "
|
|
194
|
+
method: "GET",
|
|
158
195
|
signal
|
|
159
196
|
},
|
|
160
197
|
options
|
|
@@ -175,6 +212,18 @@ var useGetDefaultOrganisation = (options) => {
|
|
|
175
212
|
query.queryKey = queryOptions.queryKey;
|
|
176
213
|
return query;
|
|
177
214
|
};
|
|
215
|
+
var getGetDefaultOrganisationSuspenseQueryOptions = (options) => {
|
|
216
|
+
const { query: queryOptions, request: requestOptions } = options ?? {};
|
|
217
|
+
const queryKey = (queryOptions == null ? void 0 : queryOptions.queryKey) ?? getGetDefaultOrganisationQueryKey();
|
|
218
|
+
const queryFn = ({ signal }) => getDefaultOrganisation(requestOptions, signal);
|
|
219
|
+
return { queryKey, queryFn, ...queryOptions };
|
|
220
|
+
};
|
|
221
|
+
var useGetDefaultOrganisationSuspense = (options) => {
|
|
222
|
+
const queryOptions = getGetDefaultOrganisationSuspenseQueryOptions(options);
|
|
223
|
+
const query = useSuspenseQuery(queryOptions);
|
|
224
|
+
query.queryKey = queryOptions.queryKey;
|
|
225
|
+
return query;
|
|
226
|
+
};
|
|
178
227
|
export {
|
|
179
228
|
createOrganisation,
|
|
180
229
|
deleteOrganisation,
|
|
@@ -183,12 +232,16 @@ export {
|
|
|
183
232
|
getDeleteOrganisationMutationOptions,
|
|
184
233
|
getGetDefaultOrganisationQueryKey,
|
|
185
234
|
getGetDefaultOrganisationQueryOptions,
|
|
235
|
+
getGetDefaultOrganisationSuspenseQueryOptions,
|
|
186
236
|
getGetOrganisationChargesQueryKey,
|
|
187
237
|
getGetOrganisationChargesQueryOptions,
|
|
238
|
+
getGetOrganisationChargesSuspenseQueryOptions,
|
|
188
239
|
getGetOrganisationQueryKey,
|
|
189
240
|
getGetOrganisationQueryOptions,
|
|
241
|
+
getGetOrganisationSuspenseQueryOptions,
|
|
190
242
|
getGetOrganisationsQueryKey,
|
|
191
243
|
getGetOrganisationsQueryOptions,
|
|
244
|
+
getGetOrganisationsSuspenseQueryOptions,
|
|
192
245
|
getOrganisation,
|
|
193
246
|
getOrganisationCharges,
|
|
194
247
|
getOrganisations,
|
|
@@ -197,9 +250,13 @@ export {
|
|
|
197
250
|
useCreateOrganisation,
|
|
198
251
|
useDeleteOrganisation,
|
|
199
252
|
useGetDefaultOrganisation,
|
|
253
|
+
useGetDefaultOrganisationSuspense,
|
|
200
254
|
useGetOrganisation,
|
|
201
255
|
useGetOrganisationCharges,
|
|
256
|
+
useGetOrganisationChargesSuspense,
|
|
257
|
+
useGetOrganisationSuspense,
|
|
202
258
|
useGetOrganisations,
|
|
259
|
+
useGetOrganisationsSuspense,
|
|
203
260
|
usePatchOrganisation
|
|
204
261
|
};
|
|
205
262
|
//# sourceMappingURL=organisation.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/organisation/organisation.ts"],"sourcesContent":["/**\n * Generated by orval v6.20.0 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 2.1\n */\nimport {\n useMutation,\n useQuery\n} from '@tanstack/react-query'\nimport type {\n MutationFunction,\n QueryFunction,\n QueryKey,\n UseMutationOptions,\n UseQueryOptions,\n UseQueryResult\n} from '@tanstack/react-query'\nimport type {\n AsError,\n GetOrganisationChargesParams,\n OrganisationChargesGetResponse,\n OrganisationDetail,\n OrganisationGetDefaultResponse,\n OrganisationPatchBodyBody,\n OrganisationPostBodyBody,\n OrganisationPostResponse,\n OrganisationsGetResponse\n} from '../account-server-api.schemas'\nimport { customInstance } from '.././custom-instance';\nimport type { ErrorType } from '.././custom-instance';\n\n\n// eslint-disable-next-line\n type SecondParameter<T extends (...args: any) => any> = T extends (\n config: any,\n args: infer P,\n) => any\n ? P\n : never;\n\n\n/**\n * Gets all the Organisations that you are a member of or are public. Admin users are members of all Organisations\n\n * @summary Gets Organisations\n */\nexport const getOrganisations = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationsGetResponse>(\n {url: `/organisation`, method: 'get', signal\n },\n options);\n }\n \n\nexport const getGetOrganisationsQueryKey = () => {\n \n return [\"account-server-api\", `/organisation`] as const;\n }\n\n \nexport const getGetOrganisationsQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>( options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationsQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisations>>> = ({ signal }) => getOrganisations(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationsQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>\nexport type GetOrganisationsQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets Organisations\n */\nexport const useGetOrganisations = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(\n options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationsQueryOptions(options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Creates a new Organisation\n\nYou need admin rights to use this method\n\n * @summary Create a new organisation\n */\nexport const createOrganisation = (\n organisationPostBodyBody: OrganisationPostBodyBody,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<OrganisationPostResponse>(\n {url: `/organisation`, method: 'post',\n headers: {'Content-Type': 'application/json', },\n data: organisationPostBodyBody\n },\n options);\n }\n \n\n\nexport const getCreateOrganisationMutationOptions = <TError = ErrorType<AsError | void>,\n \n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof createOrganisation>>, {data: OrganisationPostBodyBody}> = (props) => {\n const {data} = props ?? {};\n\n return createOrganisation(data,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type CreateOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof createOrganisation>>>\n export type CreateOrganisationMutationBody = OrganisationPostBodyBody\n export type CreateOrganisationMutationError = ErrorType<AsError | void>\n\n /**\n * @summary Create a new organisation\n */\nexport const useCreateOrganisation = <TError = ErrorType<AsError | void>,\n \n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getCreateOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Gets a specific Organisation. To see the Organisation you need admin rights or need to be a member of the Organisation.\n\nMembers of an Organisation's **Unit** do not necessarily have access to the Organisation.\n\n * @summary Gets an Organisation\n */\nexport const getOrganisation = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationDetail>(\n {url: `/organisation/${orgId}`, method: 'get', signal\n },\n options);\n }\n \n\nexport const getGetOrganisationQueryKey = (orgId: string,) => {\n \n return [\"account-server-api\", `/organisation/${orgId}`] as const;\n }\n\n \nexport const getGetOrganisationQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationQueryKey(orgId);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisation>>> = ({ signal }) => getOrganisation(orgId, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>\nexport type GetOrganisationQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets an Organisation\n */\nexport const useGetOrganisation = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(\n orgId: string, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationQueryOptions(orgId,options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Used to update existing Organisation.\n\nYou have to be the Organisation owner (or an administrator) to patch an Organisation.\n\n * @summary Adjust an existing Organisation\n */\nexport const patchOrganisation = (\n orgId: string,\n organisationPatchBodyBody: OrganisationPatchBodyBody,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/organisation/${orgId}`, method: 'patch',\n headers: {'Content-Type': 'application/json', },\n data: organisationPatchBodyBody\n },\n options);\n }\n \n\n\nexport const getPatchOrganisationMutationOptions = <TError = ErrorType<AsError>,\n \n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof patchOrganisation>>, {orgId: string;data: OrganisationPatchBodyBody}> = (props) => {\n const {orgId,data} = props ?? {};\n\n return patchOrganisation(orgId,data,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type PatchOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof patchOrganisation>>>\n export type PatchOrganisationMutationBody = OrganisationPatchBodyBody\n export type PatchOrganisationMutationError = ErrorType<AsError>\n\n /**\n * @summary Adjust an existing Organisation\n */\nexport const usePatchOrganisation = <TError = ErrorType<AsError>,\n \n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getPatchOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Before an Organisation can be deleted all its underlying **Units** must also be deleted, remembering that **Units** that have undeleted **Products** cannot be deleted.\n\nYou need admin rights to use this method\n\n * @summary Deletes an Organisation\n */\nexport const deleteOrganisation = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/organisation/${orgId}`, method: 'delete'\n },\n options);\n }\n \n\n\nexport const getDeleteOrganisationMutationOptions = <TError = ErrorType<AsError>,\n \n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof deleteOrganisation>>, {orgId: string}> = (props) => {\n const {orgId} = props ?? {};\n\n return deleteOrganisation(orgId,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type DeleteOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof deleteOrganisation>>>\n \n export type DeleteOrganisationMutationError = ErrorType<AsError>\n\n /**\n * @summary Deletes an Organisation\n */\nexport const useDeleteOrganisation = <TError = ErrorType<AsError>,\n \n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getDeleteOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Gets a Organisation charges.\n\nThe Organisation cannot be the **Default Organisation** and you need to be a member of the Organisation to use this endpoint\n\n * @summary Gets charges for all Units in an Organisation\n */\nexport const getOrganisationCharges = (\n orgId: string,\n params?: GetOrganisationChargesParams,\n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationChargesGetResponse>(\n {url: `/organisation/${orgId}/charges`, method: 'get',\n params, signal\n },\n options);\n }\n \n\nexport const getGetOrganisationChargesQueryKey = (orgId: string,\n params?: GetOrganisationChargesParams,) => {\n \n return [\"account-server-api\", `/organisation/${orgId}/charges`, ...(params ? [params]: [])] as const;\n }\n\n \nexport const getGetOrganisationChargesQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationChargesQueryKey(orgId,params);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationCharges>>> = ({ signal }) => getOrganisationCharges(orgId,params, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationChargesQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>\nexport type GetOrganisationChargesQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets charges for all Units in an Organisation\n */\nexport const useGetOrganisationCharges = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(\n orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationChargesQueryOptions(orgId,params,options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.\n\nAny authorised user can see the Default Organisation.\n\n * @summary Gets the Default Organisation\n */\nexport const getDefaultOrganisation = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationGetDefaultResponse>(\n {url: `/organisation/default`, method: 'get', signal\n },\n options);\n }\n \n\nexport const getGetDefaultOrganisationQueryKey = () => {\n \n return [\"account-server-api\", `/organisation/default`] as const;\n }\n\n \nexport const getGetDefaultOrganisationQueryOptions = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>( options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetDefaultOrganisationQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getDefaultOrganisation>>> = ({ signal }) => getDefaultOrganisation(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetDefaultOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>\nexport type GetDefaultOrganisationQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets the Default Organisation\n */\nexport const useGetDefaultOrganisation = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(\n options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetDefaultOrganisationQueryOptions(options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n"],"mappings":";;;;;AAUA;AAAA,EACE;AAAA,EACA;AAAA,OACK;AAsCA,IAAM,mBAAmB,CAE/B,SAAiD,WAC7C;AAGC,SAAO;AAAA,IACP;AAAA,MAAC,KAAK;AAAA,MAAiB,QAAQ;AAAA,MAAO;AAAA,IACxC;AAAA,IACE;AAAA,EAAO;AACT;AAGG,IAAM,8BAA8B,MAAM;AAE7C,SAAO,CAAC,sBAAsB,eAAe;AAC7C;AAGG,IAAM,kCAAkC,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,MAAO;AAAA,IAChD;AAAA,IACE;AAAA,EAAO;AACT;AAGG,IAAM,oCAAoC,MAAM;AAEnD,SAAO,CAAC,sBAAsB,uBAAuB;AACrD;AAGG,IAAM,wCAAwC,CAAkG,YAClJ;AAEL,QAAM,EAAC,OAAO,cAAc,SAAS,eAAc,IAAI,WAAW,CAAC;AAEjE,QAAM,YAAY,6CAAc,aAAY,kCAAkC;AAI5E,QAAM,UAA6E,CAAC,EAAE,OAAO,MAAM,uBAAuB,gBAAgB,MAAM;AAMjJ,SAAQ,EAAE,UAAU,SAAS,GAAG,aAAY;AAC/C;AAQO,IAAM,4BAA4B,CACvC,YAE8D;AAE9D,QAAM,eAAe,sCAAsC,OAAO;AAElE,QAAM,QAAQ,SAAS,YAAY;AAEnC,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../../src/organisation/organisation.ts"],"sourcesContent":["/**\n * Generated by orval v6.25.0 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 2.1\n */\nimport {\n useMutation,\n useQuery,\n useSuspenseQuery\n} from '@tanstack/react-query'\nimport type {\n MutationFunction,\n QueryFunction,\n QueryKey,\n UseMutationOptions,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult\n} from '@tanstack/react-query'\nimport type {\n AsError,\n GetOrganisationChargesParams,\n OrganisationChargesGetResponse,\n OrganisationDetail,\n OrganisationGetDefaultResponse,\n OrganisationPatchBodyBody,\n OrganisationPostBodyBody,\n OrganisationPostResponse,\n OrganisationsGetResponse\n} from '../account-server-api.schemas'\nimport { customInstance } from '.././custom-instance';\nimport type { ErrorType } from '.././custom-instance';\n\n\ntype SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];\n\n\n/**\n * Gets all the Organisations that you are a member of or are public. Admin users are members of all Organisations\n\n * @summary Gets Organisations\n */\nexport const getOrganisations = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationsGetResponse>(\n {url: `/organisation`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetOrganisationsQueryKey = () => {\n return [\"account-server-api\", `/organisation`] as const;\n }\n\n \nexport const getGetOrganisationsQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationsQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisations>>> = ({ signal }) => getOrganisations(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationsQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>\nexport type GetOrganisationsQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets Organisations\n */\nexport const useGetOrganisations = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationsQueryOptions(options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\nexport const getGetOrganisationsSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationsQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisations>>> = ({ signal }) => getOrganisations(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationsSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>\nexport type GetOrganisationsSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets Organisations\n */\nexport const useGetOrganisationsSuspense = <TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationsSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Creates a new Organisation\n\nYou need admin rights to use this method\n\n * @summary Create a new organisation\n */\nexport const createOrganisation = (\n organisationPostBodyBody: OrganisationPostBodyBody,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<OrganisationPostResponse>(\n {url: `/organisation`, method: 'POST',\n headers: {'Content-Type': 'application/json', },\n data: organisationPostBodyBody\n },\n options);\n }\n \n\n\nexport const getCreateOrganisationMutationOptions = <TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof createOrganisation>>, {data: OrganisationPostBodyBody}> = (props) => {\n const {data} = props ?? {};\n\n return createOrganisation(data,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type CreateOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof createOrganisation>>>\n export type CreateOrganisationMutationBody = OrganisationPostBodyBody\n export type CreateOrganisationMutationError = ErrorType<AsError | void>\n\n /**\n * @summary Create a new organisation\n */\nexport const useCreateOrganisation = <TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError,{data: OrganisationPostBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getCreateOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Gets a specific Organisation. To see the Organisation you need admin rights or need to be a member of the Organisation.\n\nMembers of an Organisation's **Unit** do not necessarily have access to the Organisation.\n\n * @summary Gets an Organisation\n */\nexport const getOrganisation = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationDetail>(\n {url: `/organisation/${orgId}`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetOrganisationQueryKey = (orgId: string,) => {\n return [\"account-server-api\", `/organisation/${orgId}`] as const;\n }\n\n \nexport const getGetOrganisationQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationQueryKey(orgId);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisation>>> = ({ signal }) => getOrganisation(orgId, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>\nexport type GetOrganisationQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets an Organisation\n */\nexport const useGetOrganisation = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(\n orgId: string, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationQueryOptions(orgId,options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\nexport const getGetOrganisationSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationQueryKey(orgId);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisation>>> = ({ signal }) => getOrganisation(orgId, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>\nexport type GetOrganisationSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets an Organisation\n */\nexport const useGetOrganisationSuspense = <TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(\n orgId: string, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationSuspenseQueryOptions(orgId,options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Used to update existing Organisation.\n\nYou have to be the Organisation owner (or an administrator) to patch an Organisation.\n\n * @summary Adjust an existing Organisation\n */\nexport const patchOrganisation = (\n orgId: string,\n organisationPatchBodyBody: OrganisationPatchBodyBody,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/organisation/${orgId}`, method: 'PATCH',\n headers: {'Content-Type': 'application/json', },\n data: organisationPatchBodyBody\n },\n options);\n }\n \n\n\nexport const getPatchOrganisationMutationOptions = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof patchOrganisation>>, {orgId: string;data: OrganisationPatchBodyBody}> = (props) => {\n const {orgId,data} = props ?? {};\n\n return patchOrganisation(orgId,data,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type PatchOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof patchOrganisation>>>\n export type PatchOrganisationMutationBody = OrganisationPatchBodyBody\n export type PatchOrganisationMutationError = ErrorType<AsError>\n\n /**\n * @summary Adjust an existing Organisation\n */\nexport const usePatchOrganisation = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError,{orgId: string;data: OrganisationPatchBodyBody}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getPatchOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Before an Organisation can be deleted all its underlying **Units** must also be deleted, remembering that **Units** that have undeleted **Products** cannot be deleted.\n\nYou need admin rights to use this method\n\n * @summary Deletes an Organisation\n */\nexport const deleteOrganisation = (\n orgId: string,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/organisation/${orgId}`, method: 'DELETE'\n },\n options);\n }\n \n\n\nexport const getDeleteOrganisationMutationOptions = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext> => {\n const {mutation: mutationOptions, request: requestOptions} = options ?? {};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof deleteOrganisation>>, {orgId: string}> = (props) => {\n const {orgId} = props ?? {};\n\n return deleteOrganisation(orgId,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions }}\n\n export type DeleteOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof deleteOrganisation>>>\n \n export type DeleteOrganisationMutationError = ErrorType<AsError>\n\n /**\n * @summary Deletes an Organisation\n */\nexport const useDeleteOrganisation = <TError = ErrorType<AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError,{orgId: string}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\n\n const mutationOptions = getDeleteOrganisationMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Gets a Organisation charges.\n\nThe Organisation cannot be the **Default Organisation** and you need to be a member of the Organisation to use this endpoint\n\n * @summary Gets charges for all Units in an Organisation\n */\nexport const getOrganisationCharges = (\n orgId: string,\n params?: GetOrganisationChargesParams,\n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationChargesGetResponse>(\n {url: `/organisation/${orgId}/charges`, method: 'GET',\n params, signal\n },\n options);\n }\n \n\nexport const getGetOrganisationChargesQueryKey = (orgId: string,\n params?: GetOrganisationChargesParams,) => {\n return [\"account-server-api\", `/organisation/${orgId}/charges`, ...(params ? [params]: [])] as const;\n }\n\n \nexport const getGetOrganisationChargesQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationChargesQueryKey(orgId,params);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationCharges>>> = ({ signal }) => getOrganisationCharges(orgId,params, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationChargesQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>\nexport type GetOrganisationChargesQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets charges for all Units in an Organisation\n */\nexport const useGetOrganisationCharges = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(\n orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationChargesQueryOptions(orgId,params,options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\nexport const getGetOrganisationChargesSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetOrganisationChargesQueryKey(orgId,params);\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getOrganisationCharges>>> = ({ signal }) => getOrganisationCharges(orgId,params, requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, enabled: !!(orgId), ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetOrganisationChargesSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisationCharges>>>\nexport type GetOrganisationChargesSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets charges for all Units in an Organisation\n */\nexport const useGetOrganisationChargesSuspense = <TData = Awaited<ReturnType<typeof getOrganisationCharges>>, TError = ErrorType<void | AsError>>(\n orgId: string,\n params?: GetOrganisationChargesParams, options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisationCharges>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetOrganisationChargesSuspenseQueryOptions(orgId,params,options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Gets the Default Organisation, a built-in Organisation used exclusively for **Personal Units**.\n\nAny authorised user can see the Default Organisation.\n\n * @summary Gets the Default Organisation\n */\nexport const getDefaultOrganisation = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<OrganisationGetDefaultResponse>(\n {url: `/organisation/default`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetDefaultOrganisationQueryKey = () => {\n return [\"account-server-api\", `/organisation/default`] as const;\n }\n\n \nexport const getGetDefaultOrganisationQueryOptions = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetDefaultOrganisationQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getDefaultOrganisation>>> = ({ signal }) => getDefaultOrganisation(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetDefaultOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>\nexport type GetDefaultOrganisationQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets the Default Organisation\n */\nexport const useGetDefaultOrganisation = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetDefaultOrganisationQueryOptions(options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\nexport const getGetDefaultOrganisationSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetDefaultOrganisationQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getDefaultOrganisation>>> = ({ signal }) => getDefaultOrganisation(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & { queryKey: QueryKey }\n}\n\nexport type GetDefaultOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>\nexport type GetDefaultOrganisationSuspenseQueryError = ErrorType<void | AsError>\n\n/**\n * @summary Gets the Default Organisation\n */\nexport const useGetDefaultOrganisationSuspense = <TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n\n const queryOptions = getGetDefaultOrganisationSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n"],"mappings":";;;;;AAUA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAkCA,IAAM,mBAAmB,CAE/B,SAAiD,WAC7C;AAGC,SAAO;AAAA,IACP;AAAA,MAAC,KAAK;AAAA,MAAiB,QAAQ;AAAA,MAAO;AAAA,IACxC;AAAA,IACE;AAAA,EAAO;AACT;AAGG,IAAM,8BAA8B,MAAM;AAC7C,SAAO,CAAC,sBAAsB,eAAe;AAC7C;AAGG,IAAM,kCAAkC,CAA4F,YACtI;AAEL,QAAM,EAAC,OAAO,cAAc,SAAS,eAAc,IAAI,WAAW,CAAC;AAEjE,QAAM,YAAY,6CAAc,aAAY,4BAA4B;AAItE,QAAM,UAAuE,CAAC,EAAE,OAAO,MAAM,iBAAiB,gBAAgB,MAAM;AAMrI,SAAQ,EAAE,UAAU,SAAS,GAAG,aAAY;AAC/C;AAQO,IAAM,sBAAsB,CACjC,YAE8D;AAE9D,QAAM,eAAe,gCAAgC,OAAO;AAE5D,QAAM,QAAQ,SAAS,YAAY;AAEnC,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT;AAIO,IAAM,0CAA0C,CAA4F,YAC9I;AAEL,QAAM,EAAC,OAAO,cAAc,SAAS,eAAc,IAAI,WAAW,CAAC;AAEjE,QAAM,YAAY,6CAAc,aAAY,4BAA4B;AAItE,QAAM,UAAuE,CAAC,EAAE,OAAO,MAAM,iBAAiB,gBAAgB,MAAM;AAMrI,SAAQ,EAAE,UAAU,SAAS,GAAG,aAAY;AAC/C;AAQO,IAAM,8BAA8B,CACzC,YAEsE;AAEtE,QAAM,eAAe,wCAAwC,OAAO;AAEpE,QAAM,QAAQ,iBAAiB,YAAY;AAE3C,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT;AAWO,IAAM,qBAAqB,CAC9B,0BACH,Y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AAgB,MAAM;AAMjJ,SAAQ,EAAE,UAAU,SAAS,GAAG,aAAY;AAC/C;AAQO,IAAM,oCAAoC,CAC/C,YAEsE;AAEtE,QAAM,eAAe,8CAA8C,OAAO;AAE1E,QAAM,QAAQ,iBAAiB,YAAY;AAE3C,QAAM,WAAW,aAAa;AAE9B,SAAO;AACT;","names":[]}
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "2.1.0
|
|
2
|
+
"version": "2.1.0",
|
|
3
3
|
"author": "Oliver Dudgeon",
|
|
4
4
|
"name": "@squonk/account-server-client",
|
|
5
5
|
"private": false,
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
"type": "git",
|
|
8
8
|
"url": "https://github.com/InformaticsMatters/squonk2-account-server-js-client"
|
|
9
9
|
},
|
|
10
|
-
"description": "TypeScript client for the Squonk Account Server API. Generated from the Open API spec with orval. Provides React Hooks to fetch data with react-query
|
|
10
|
+
"description": "TypeScript client for the Squonk Account Server API. Generated from the Open API spec with orval. Provides React Hooks to fetch data with react-query using Axios under-the-hood.",
|
|
11
11
|
"license": "MIT",
|
|
12
12
|
"type": "module",
|
|
13
13
|
"scripts": {
|
|
@@ -15,18 +15,18 @@
|
|
|
15
15
|
"build": "tsup && node setup-entrypoints.js"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
|
-
"@tanstack/react-query": "
|
|
19
|
-
"@typescript-eslint/eslint-plugin": "
|
|
20
|
-
"axios": "1.6.
|
|
21
|
-
"eslint": "8.
|
|
22
|
-
"eslint-plugin-prettier": "5.
|
|
18
|
+
"@tanstack/react-query": "5.24.1",
|
|
19
|
+
"@typescript-eslint/eslint-plugin": "7.1.0",
|
|
20
|
+
"axios": "1.6.7",
|
|
21
|
+
"eslint": "8.57.0",
|
|
22
|
+
"eslint-plugin-prettier": "5.1.3",
|
|
23
23
|
"js-yaml": "4.1.0",
|
|
24
|
-
"orval": "6.
|
|
25
|
-
"prettier": "3.
|
|
26
|
-
"ts-morph": "
|
|
24
|
+
"orval": "6.25.0",
|
|
25
|
+
"prettier": "3.2.5",
|
|
26
|
+
"ts-morph": "21.0.1",
|
|
27
27
|
"tslib": "2.6.2",
|
|
28
|
-
"tsup": "
|
|
29
|
-
"typescript": "5.
|
|
28
|
+
"tsup": "8.0.2",
|
|
29
|
+
"typescript": "5.3.3"
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|
|
32
32
|
"@tanstack/react-query": ">=4",
|