@squonk/account-server-client 3.1.0-alpha.3 → 4.0.0-beta.3
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/asset/asset.cjs +24 -24
- package/asset/asset.cjs.map +1 -1
- package/asset/asset.d.cts +137 -102
- package/asset/asset.d.ts +137 -102
- package/asset/asset.js +24 -24
- package/asset/asset.js.map +1 -1
- package/charges/charges.cjs +16 -16
- package/charges/charges.cjs.map +1 -1
- package/charges/charges.d.cts +137 -65
- package/charges/charges.d.ts +137 -65
- package/charges/charges.js +16 -16
- package/charges/charges.js.map +1 -1
- package/chunk-TKLTUR4R.cjs.map +1 -1
- package/event-stream/event-stream.cjs +8 -8
- package/event-stream/event-stream.cjs.map +1 -1
- package/event-stream/event-stream.d.cts +82 -47
- package/event-stream/event-stream.d.ts +82 -47
- package/event-stream/event-stream.js +8 -8
- package/event-stream/event-stream.js.map +1 -1
- package/index.cjs.map +1 -1
- package/index.d.cts +62 -14
- package/index.d.ts +62 -14
- package/index.js.map +1 -1
- package/merchant/merchant.cjs +8 -8
- package/merchant/merchant.cjs.map +1 -1
- package/merchant/merchant.d.cts +69 -33
- package/merchant/merchant.d.ts +69 -33
- package/merchant/merchant.js +8 -8
- package/merchant/merchant.js.map +1 -1
- package/organisation/organisation.cjs +14 -14
- package/organisation/organisation.cjs.map +1 -1
- package/organisation/organisation.d.cts +128 -75
- package/organisation/organisation.d.ts +128 -75
- package/organisation/organisation.js +14 -14
- package/organisation/organisation.js.map +1 -1
- package/package.json +7 -7
- package/product/product.cjs +24 -24
- package/product/product.cjs.map +1 -1
- package/product/product.d.cts +229 -122
- package/product/product.d.ts +229 -122
- package/product/product.js +24 -24
- package/product/product.js.map +1 -1
- package/src/account-server-api.schemas.ts +63 -14
- package/src/asset/asset.ts +185 -65
- package/src/charges/charges.ts +200 -18
- package/src/event-stream/event-stream.ts +114 -19
- package/src/merchant/merchant.ts +94 -10
- package/src/organisation/organisation.ts +171 -31
- package/src/product/product.ts +301 -41
- package/src/state/state.ts +50 -6
- package/src/unit/unit.ts +188 -38
- package/src/user/user.ts +183 -38
- package/state/state.cjs +4 -4
- package/state/state.cjs.map +1 -1
- package/state/state.d.cts +35 -17
- package/state/state.d.ts +35 -17
- package/state/state.js +4 -4
- package/state/state.js.map +1 -1
- package/unit/unit.cjs +12 -12
- package/unit/unit.cjs.map +1 -1
- package/unit/unit.d.cts +140 -87
- package/unit/unit.d.ts +140 -87
- package/unit/unit.js +12 -12
- package/unit/unit.js.map +1 -1
- package/user/user.cjs +12 -12
- package/user/user.cjs.map +1 -1
- package/user/user.d.cts +139 -86
- package/user/user.d.ts +139 -86
- package/user/user.js +12 -12
- package/user/user.js.map +1 -1
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { UseQueryOptions, QueryKey, UseQueryResult, UseSuspenseQueryOptions, UseSuspenseQueryResult, UseMutationOptions } from '@tanstack/react-query';
|
|
1
|
+
import { UseQueryOptions, QueryKey, DefinedInitialDataOptions, DefinedUseQueryResult, UndefinedInitialDataOptions, UseQueryResult, UseSuspenseQueryOptions, UseSuspenseQueryResult, UseMutationOptions, UseMutationResult } from '@tanstack/react-query';
|
|
3
2
|
import { customInstance, OrganisationsGetResponse, ErrorType, AsError, OrganisationPostBodyBody, OrganisationPostResponse, OrganisationAllDetail, OrganisationPatchBodyBody, OrganisationGetDefaultResponse } from '../index.cjs';
|
|
4
3
|
import 'axios';
|
|
5
4
|
|
|
@@ -14,37 +13,55 @@ You can see an Organisation if you are a member of it, the owner (creator) of it
|
|
|
14
13
|
declare const getOrganisations: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationsGetResponse>;
|
|
15
14
|
declare const getGetOrganisationsQueryKey: () => readonly ["account-server-api", "/organisation"];
|
|
16
15
|
declare const getGetOrganisationsQueryOptions: <TData = OrganisationsGetResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
17
|
-
query?: Partial<UseQueryOptions<
|
|
16
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>;
|
|
18
17
|
request?: SecondParameter<typeof customInstance>;
|
|
19
|
-
}
|
|
18
|
+
}) => UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & {
|
|
20
19
|
queryKey: QueryKey;
|
|
21
20
|
};
|
|
22
21
|
type GetOrganisationsQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>;
|
|
23
22
|
type GetOrganisationsQueryError = ErrorType<void | AsError>;
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
*/
|
|
27
|
-
declare const useGetOrganisations: <TData = OrganisationsGetResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
28
|
-
query?: Partial<UseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey>> | undefined;
|
|
23
|
+
declare function useGetOrganisations<TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(options: {
|
|
24
|
+
query: Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>> & Pick<DefinedInitialDataOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>, 'initialData'>;
|
|
29
25
|
request?: SecondParameter<typeof customInstance>;
|
|
30
|
-
}
|
|
26
|
+
}): DefinedUseQueryResult<TData, TError> & {
|
|
27
|
+
queryKey: QueryKey;
|
|
28
|
+
};
|
|
29
|
+
declare function useGetOrganisations<TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(options?: {
|
|
30
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>> & Pick<UndefinedInitialDataOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>, 'initialData'>;
|
|
31
|
+
request?: SecondParameter<typeof customInstance>;
|
|
32
|
+
}): UseQueryResult<TData, TError> & {
|
|
33
|
+
queryKey: QueryKey;
|
|
34
|
+
};
|
|
35
|
+
declare function useGetOrganisations<TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(options?: {
|
|
36
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>;
|
|
37
|
+
request?: SecondParameter<typeof customInstance>;
|
|
38
|
+
}): UseQueryResult<TData, TError> & {
|
|
31
39
|
queryKey: QueryKey;
|
|
32
40
|
};
|
|
33
41
|
declare const getGetOrganisationsSuspenseQueryOptions: <TData = OrganisationsGetResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
34
|
-
query?: Partial<UseSuspenseQueryOptions<
|
|
42
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>;
|
|
35
43
|
request?: SecondParameter<typeof customInstance>;
|
|
36
|
-
}
|
|
44
|
+
}) => UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData> & {
|
|
37
45
|
queryKey: QueryKey;
|
|
38
46
|
};
|
|
39
47
|
type GetOrganisationsSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisations>>>;
|
|
40
48
|
type GetOrganisationsSuspenseQueryError = ErrorType<void | AsError>;
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
*/
|
|
44
|
-
declare const useGetOrganisationsSuspense: <TData = OrganisationsGetResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
45
|
-
query?: Partial<UseSuspenseQueryOptions<OrganisationsGetResponse, TError, TData, QueryKey>> | undefined;
|
|
49
|
+
declare function useGetOrganisationsSuspense<TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(options: {
|
|
50
|
+
query: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>;
|
|
46
51
|
request?: SecondParameter<typeof customInstance>;
|
|
47
|
-
}
|
|
52
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
53
|
+
queryKey: QueryKey;
|
|
54
|
+
};
|
|
55
|
+
declare function useGetOrganisationsSuspense<TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(options?: {
|
|
56
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>;
|
|
57
|
+
request?: SecondParameter<typeof customInstance>;
|
|
58
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
59
|
+
queryKey: QueryKey;
|
|
60
|
+
};
|
|
61
|
+
declare function useGetOrganisationsSuspense<TData = Awaited<ReturnType<typeof getOrganisations>>, TError = ErrorType<void | AsError>>(options?: {
|
|
62
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisations>>, TError, TData>>;
|
|
63
|
+
request?: SecondParameter<typeof customInstance>;
|
|
64
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
48
65
|
queryKey: QueryKey;
|
|
49
66
|
};
|
|
50
67
|
/**
|
|
@@ -58,11 +75,11 @@ You need admin rights to use this method
|
|
|
58
75
|
*/
|
|
59
76
|
declare const createOrganisation: (organisationPostBodyBody: OrganisationPostBodyBody, options?: SecondParameter<typeof customInstance>) => Promise<OrganisationPostResponse>;
|
|
60
77
|
declare const getCreateOrganisationMutationOptions: <TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
|
|
61
|
-
mutation?: UseMutationOptions<
|
|
78
|
+
mutation?: UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError, {
|
|
62
79
|
data: OrganisationPostBodyBody;
|
|
63
|
-
}, TContext
|
|
80
|
+
}, TContext>;
|
|
64
81
|
request?: SecondParameter<typeof customInstance>;
|
|
65
|
-
}
|
|
82
|
+
}) => UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError, {
|
|
66
83
|
data: OrganisationPostBodyBody;
|
|
67
84
|
}, TContext>;
|
|
68
85
|
type CreateOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof createOrganisation>>>;
|
|
@@ -72,11 +89,11 @@ type CreateOrganisationMutationError = ErrorType<AsError | void>;
|
|
|
72
89
|
* @summary Create a new organisation
|
|
73
90
|
*/
|
|
74
91
|
declare const useCreateOrganisation: <TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
|
|
75
|
-
mutation?: UseMutationOptions<
|
|
92
|
+
mutation?: UseMutationOptions<Awaited<ReturnType<typeof createOrganisation>>, TError, {
|
|
76
93
|
data: OrganisationPostBodyBody;
|
|
77
|
-
}, TContext
|
|
94
|
+
}, TContext>;
|
|
78
95
|
request?: SecondParameter<typeof customInstance>;
|
|
79
|
-
}
|
|
96
|
+
}) => UseMutationResult<Awaited<ReturnType<typeof createOrganisation>>, TError, {
|
|
80
97
|
data: OrganisationPostBodyBody;
|
|
81
98
|
}, TContext>;
|
|
82
99
|
/**
|
|
@@ -89,37 +106,55 @@ Members of an Organisation's **Unit** do not have access to the Organisation.
|
|
|
89
106
|
declare const getOrganisation: (orgId: string, options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationAllDetail>;
|
|
90
107
|
declare const getGetOrganisationQueryKey: (orgId: string) => readonly ["account-server-api", `/organisation/${string}`];
|
|
91
108
|
declare const getGetOrganisationQueryOptions: <TData = OrganisationAllDetail, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
92
|
-
query?: Partial<UseQueryOptions<
|
|
109
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>;
|
|
93
110
|
request?: SecondParameter<typeof customInstance>;
|
|
94
|
-
}
|
|
111
|
+
}) => UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & {
|
|
95
112
|
queryKey: QueryKey;
|
|
96
113
|
};
|
|
97
114
|
type GetOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>;
|
|
98
115
|
type GetOrganisationQueryError = ErrorType<void | AsError>;
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
116
|
+
declare function useGetOrganisation<TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options: {
|
|
117
|
+
query: Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>> & Pick<DefinedInitialDataOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>, 'initialData'>;
|
|
118
|
+
request?: SecondParameter<typeof customInstance>;
|
|
119
|
+
}): DefinedUseQueryResult<TData, TError> & {
|
|
120
|
+
queryKey: QueryKey;
|
|
121
|
+
};
|
|
122
|
+
declare function useGetOrganisation<TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
123
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>> & Pick<UndefinedInitialDataOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>, 'initialData'>;
|
|
124
|
+
request?: SecondParameter<typeof customInstance>;
|
|
125
|
+
}): UseQueryResult<TData, TError> & {
|
|
126
|
+
queryKey: QueryKey;
|
|
127
|
+
};
|
|
128
|
+
declare function useGetOrganisation<TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
129
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>;
|
|
104
130
|
request?: SecondParameter<typeof customInstance>;
|
|
105
|
-
}
|
|
131
|
+
}): UseQueryResult<TData, TError> & {
|
|
106
132
|
queryKey: QueryKey;
|
|
107
133
|
};
|
|
108
134
|
declare const getGetOrganisationSuspenseQueryOptions: <TData = OrganisationAllDetail, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
109
|
-
query?: Partial<UseSuspenseQueryOptions<
|
|
135
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>;
|
|
110
136
|
request?: SecondParameter<typeof customInstance>;
|
|
111
|
-
}
|
|
137
|
+
}) => UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData> & {
|
|
112
138
|
queryKey: QueryKey;
|
|
113
139
|
};
|
|
114
140
|
type GetOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getOrganisation>>>;
|
|
115
141
|
type GetOrganisationSuspenseQueryError = ErrorType<void | AsError>;
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
*/
|
|
119
|
-
declare const useGetOrganisationSuspense: <TData = OrganisationAllDetail, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
120
|
-
query?: Partial<UseSuspenseQueryOptions<OrganisationAllDetail, TError, TData, QueryKey>> | undefined;
|
|
142
|
+
declare function useGetOrganisationSuspense<TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options: {
|
|
143
|
+
query: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>;
|
|
121
144
|
request?: SecondParameter<typeof customInstance>;
|
|
122
|
-
}
|
|
145
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
146
|
+
queryKey: QueryKey;
|
|
147
|
+
};
|
|
148
|
+
declare function useGetOrganisationSuspense<TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
149
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>;
|
|
150
|
+
request?: SecondParameter<typeof customInstance>;
|
|
151
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
152
|
+
queryKey: QueryKey;
|
|
153
|
+
};
|
|
154
|
+
declare function useGetOrganisationSuspense<TData = Awaited<ReturnType<typeof getOrganisation>>, TError = ErrorType<void | AsError>>(orgId: string, options?: {
|
|
155
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getOrganisation>>, TError, TData>>;
|
|
156
|
+
request?: SecondParameter<typeof customInstance>;
|
|
157
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
123
158
|
queryKey: QueryKey;
|
|
124
159
|
};
|
|
125
160
|
/**
|
|
@@ -130,29 +165,29 @@ You have to be a member of the **Organisation**, its creator, or an administrato
|
|
|
130
165
|
* @summary Adjust an existing Organisation
|
|
131
166
|
*/
|
|
132
167
|
declare const patchOrganisation: (orgId: string, organisationPatchBodyBody: OrganisationPatchBodyBody, options?: SecondParameter<typeof customInstance>) => Promise<void>;
|
|
133
|
-
declare const getPatchOrganisationMutationOptions: <TError = ErrorType<AsError>, TContext = unknown>(options?: {
|
|
134
|
-
mutation?: UseMutationOptions<
|
|
168
|
+
declare const getPatchOrganisationMutationOptions: <TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
|
|
169
|
+
mutation?: UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError, {
|
|
135
170
|
orgId: string;
|
|
136
171
|
data: OrganisationPatchBodyBody;
|
|
137
|
-
}, TContext
|
|
172
|
+
}, TContext>;
|
|
138
173
|
request?: SecondParameter<typeof customInstance>;
|
|
139
|
-
}
|
|
174
|
+
}) => UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError, {
|
|
140
175
|
orgId: string;
|
|
141
176
|
data: OrganisationPatchBodyBody;
|
|
142
177
|
}, TContext>;
|
|
143
178
|
type PatchOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof patchOrganisation>>>;
|
|
144
179
|
type PatchOrganisationMutationBody = OrganisationPatchBodyBody;
|
|
145
|
-
type PatchOrganisationMutationError = ErrorType<AsError>;
|
|
180
|
+
type PatchOrganisationMutationError = ErrorType<void | AsError>;
|
|
146
181
|
/**
|
|
147
182
|
* @summary Adjust an existing Organisation
|
|
148
183
|
*/
|
|
149
|
-
declare const usePatchOrganisation: <TError = ErrorType<AsError>, TContext = unknown>(options?: {
|
|
150
|
-
mutation?: UseMutationOptions<
|
|
184
|
+
declare const usePatchOrganisation: <TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
|
|
185
|
+
mutation?: UseMutationOptions<Awaited<ReturnType<typeof patchOrganisation>>, TError, {
|
|
151
186
|
orgId: string;
|
|
152
187
|
data: OrganisationPatchBodyBody;
|
|
153
|
-
}, TContext
|
|
188
|
+
}, TContext>;
|
|
154
189
|
request?: SecondParameter<typeof customInstance>;
|
|
155
|
-
}
|
|
190
|
+
}) => UseMutationResult<Awaited<ReturnType<typeof patchOrganisation>>, TError, {
|
|
156
191
|
orgId: string;
|
|
157
192
|
data: OrganisationPatchBodyBody;
|
|
158
193
|
}, TContext>;
|
|
@@ -164,25 +199,25 @@ You need admin rights to use this method
|
|
|
164
199
|
* @summary Deletes an Organisation
|
|
165
200
|
*/
|
|
166
201
|
declare const deleteOrganisation: (orgId: string, options?: SecondParameter<typeof customInstance>) => Promise<void>;
|
|
167
|
-
declare const getDeleteOrganisationMutationOptions: <TError = ErrorType<AsError>, TContext = unknown>(options?: {
|
|
168
|
-
mutation?: UseMutationOptions<
|
|
202
|
+
declare const getDeleteOrganisationMutationOptions: <TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
|
|
203
|
+
mutation?: UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError, {
|
|
169
204
|
orgId: string;
|
|
170
|
-
}, TContext
|
|
205
|
+
}, TContext>;
|
|
171
206
|
request?: SecondParameter<typeof customInstance>;
|
|
172
|
-
}
|
|
207
|
+
}) => UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError, {
|
|
173
208
|
orgId: string;
|
|
174
209
|
}, TContext>;
|
|
175
210
|
type DeleteOrganisationMutationResult = NonNullable<Awaited<ReturnType<typeof deleteOrganisation>>>;
|
|
176
|
-
type DeleteOrganisationMutationError = ErrorType<AsError>;
|
|
211
|
+
type DeleteOrganisationMutationError = ErrorType<AsError | void>;
|
|
177
212
|
/**
|
|
178
213
|
* @summary Deletes an Organisation
|
|
179
214
|
*/
|
|
180
|
-
declare const useDeleteOrganisation: <TError = ErrorType<AsError>, TContext = unknown>(options?: {
|
|
181
|
-
mutation?: UseMutationOptions<
|
|
215
|
+
declare const useDeleteOrganisation: <TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
|
|
216
|
+
mutation?: UseMutationOptions<Awaited<ReturnType<typeof deleteOrganisation>>, TError, {
|
|
182
217
|
orgId: string;
|
|
183
|
-
}, TContext
|
|
218
|
+
}, TContext>;
|
|
184
219
|
request?: SecondParameter<typeof customInstance>;
|
|
185
|
-
}
|
|
220
|
+
}) => UseMutationResult<Awaited<ReturnType<typeof deleteOrganisation>>, TError, {
|
|
186
221
|
orgId: string;
|
|
187
222
|
}, TContext>;
|
|
188
223
|
/**
|
|
@@ -193,39 +228,57 @@ Any authorised user can see the Default Organisation.
|
|
|
193
228
|
* @summary Gets the Default Organisation
|
|
194
229
|
*/
|
|
195
230
|
declare const getDefaultOrganisation: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<OrganisationGetDefaultResponse>;
|
|
196
|
-
declare const getGetDefaultOrganisationQueryKey: () => readonly ["account-server-api", "/organisation
|
|
231
|
+
declare const getGetDefaultOrganisationQueryKey: () => readonly ["account-server-api", "/default/organisation"];
|
|
197
232
|
declare const getGetDefaultOrganisationQueryOptions: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
198
|
-
query?: Partial<UseQueryOptions<
|
|
233
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>;
|
|
199
234
|
request?: SecondParameter<typeof customInstance>;
|
|
200
|
-
}
|
|
235
|
+
}) => UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & {
|
|
201
236
|
queryKey: QueryKey;
|
|
202
237
|
};
|
|
203
238
|
type GetDefaultOrganisationQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>;
|
|
204
239
|
type GetDefaultOrganisationQueryError = ErrorType<void | AsError>;
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
*/
|
|
208
|
-
declare const useGetDefaultOrganisation: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
209
|
-
query?: Partial<UseQueryOptions<OrganisationGetDefaultResponse, TError, TData, QueryKey>> | undefined;
|
|
240
|
+
declare function useGetDefaultOrganisation<TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(options: {
|
|
241
|
+
query: Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>> & Pick<DefinedInitialDataOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>, 'initialData'>;
|
|
210
242
|
request?: SecondParameter<typeof customInstance>;
|
|
211
|
-
}
|
|
243
|
+
}): DefinedUseQueryResult<TData, TError> & {
|
|
244
|
+
queryKey: QueryKey;
|
|
245
|
+
};
|
|
246
|
+
declare function useGetDefaultOrganisation<TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(options?: {
|
|
247
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>> & Pick<UndefinedInitialDataOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>, 'initialData'>;
|
|
248
|
+
request?: SecondParameter<typeof customInstance>;
|
|
249
|
+
}): UseQueryResult<TData, TError> & {
|
|
250
|
+
queryKey: QueryKey;
|
|
251
|
+
};
|
|
252
|
+
declare function useGetDefaultOrganisation<TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(options?: {
|
|
253
|
+
query?: Partial<UseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>;
|
|
254
|
+
request?: SecondParameter<typeof customInstance>;
|
|
255
|
+
}): UseQueryResult<TData, TError> & {
|
|
212
256
|
queryKey: QueryKey;
|
|
213
257
|
};
|
|
214
258
|
declare const getGetDefaultOrganisationSuspenseQueryOptions: <TData = OrganisationGetDefaultResponse, TError = ErrorType<void | AsError>>(options?: {
|
|
215
|
-
query?: Partial<UseSuspenseQueryOptions<
|
|
259
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>;
|
|
216
260
|
request?: SecondParameter<typeof customInstance>;
|
|
217
|
-
}
|
|
261
|
+
}) => UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData> & {
|
|
218
262
|
queryKey: QueryKey;
|
|
219
263
|
};
|
|
220
264
|
type GetDefaultOrganisationSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getDefaultOrganisation>>>;
|
|
221
265
|
type GetDefaultOrganisationSuspenseQueryError = ErrorType<void | AsError>;
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
266
|
+
declare function useGetDefaultOrganisationSuspense<TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(options: {
|
|
267
|
+
query: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>;
|
|
268
|
+
request?: SecondParameter<typeof customInstance>;
|
|
269
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
270
|
+
queryKey: QueryKey;
|
|
271
|
+
};
|
|
272
|
+
declare function useGetDefaultOrganisationSuspense<TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(options?: {
|
|
273
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>;
|
|
274
|
+
request?: SecondParameter<typeof customInstance>;
|
|
275
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
276
|
+
queryKey: QueryKey;
|
|
277
|
+
};
|
|
278
|
+
declare function useGetDefaultOrganisationSuspense<TData = Awaited<ReturnType<typeof getDefaultOrganisation>>, TError = ErrorType<void | AsError>>(options?: {
|
|
279
|
+
query?: Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getDefaultOrganisation>>, TError, TData>>;
|
|
227
280
|
request?: SecondParameter<typeof customInstance>;
|
|
228
|
-
}
|
|
281
|
+
}): UseSuspenseQueryResult<TData, TError> & {
|
|
229
282
|
queryKey: QueryKey;
|
|
230
283
|
};
|
|
231
284
|
|