@squonk/data-manager-client 1.0.0-rc.3 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (89) hide show
  1. package/accounting/accounting.cjs +18 -5
  2. package/accounting/accounting.cjs.map +1 -1
  3. package/accounting/accounting.d.ts +1 -1
  4. package/accounting/accounting.js +18 -5
  5. package/accounting/accounting.js.map +1 -1
  6. package/admin/admin.cjs +67 -25
  7. package/admin/admin.cjs.map +1 -1
  8. package/admin/admin.d.ts +23 -6
  9. package/admin/admin.js +66 -24
  10. package/admin/admin.js.map +1 -1
  11. package/application/application.cjs +13 -7
  12. package/application/application.cjs.map +1 -1
  13. package/application/application.d.ts +3 -3
  14. package/application/application.js +13 -7
  15. package/application/application.js.map +1 -1
  16. package/chunk-3O5KIRV4.js +27 -0
  17. package/{chunk-3TENYKS7.js.map → chunk-3O5KIRV4.js.map} +1 -1
  18. package/chunk-IUEU2LYC.cjs +27 -0
  19. package/chunk-IUEU2LYC.cjs.map +1 -0
  20. package/{custom-instance-b2f7dca1.d.ts → custom-instance-3a73945d.d.ts} +56 -19
  21. package/dataset/dataset.cjs +92 -44
  22. package/dataset/dataset.cjs.map +1 -1
  23. package/dataset/dataset.d.ts +5 -5
  24. package/dataset/dataset.js +92 -44
  25. package/dataset/dataset.js.map +1 -1
  26. package/exchange-rate/exchange-rate.cjs +45 -27
  27. package/exchange-rate/exchange-rate.cjs.map +1 -1
  28. package/exchange-rate/exchange-rate.d.ts +3 -3
  29. package/exchange-rate/exchange-rate.js +45 -27
  30. package/exchange-rate/exchange-rate.js.map +1 -1
  31. package/file/file.cjs +39 -17
  32. package/file/file.cjs.map +1 -1
  33. package/file/file.d.ts +1 -1
  34. package/file/file.js +39 -17
  35. package/file/file.js.map +1 -1
  36. package/index.cjs +2 -2
  37. package/index.cjs.map +1 -1
  38. package/index.d.ts +1 -1
  39. package/index.js +1 -1
  40. package/index.js.map +1 -1
  41. package/instance/instance.cjs +42 -18
  42. package/instance/instance.cjs.map +1 -1
  43. package/instance/instance.d.ts +6 -6
  44. package/instance/instance.js +42 -18
  45. package/instance/instance.js.map +1 -1
  46. package/job/job.cjs +23 -7
  47. package/job/job.cjs.map +1 -1
  48. package/job/job.d.ts +3 -3
  49. package/job/job.js +23 -7
  50. package/job/job.js.map +1 -1
  51. package/metadata/metadata.cjs +43 -27
  52. package/metadata/metadata.cjs.map +1 -1
  53. package/metadata/metadata.d.ts +6 -4
  54. package/metadata/metadata.js +43 -27
  55. package/metadata/metadata.js.map +1 -1
  56. package/package.json +5 -5
  57. package/project/project.cjs +74 -39
  58. package/project/project.cjs.map +1 -1
  59. package/project/project.d.ts +13 -13
  60. package/project/project.js +74 -39
  61. package/project/project.js.map +1 -1
  62. package/src/admin/admin.ts +61 -4
  63. package/src/application/application.ts +2 -2
  64. package/src/data-manager-api.schemas.ts +59 -20
  65. package/src/dataset/dataset.ts +4 -4
  66. package/src/exchange-rate/exchange-rate.ts +2 -2
  67. package/src/instance/instance.ts +5 -5
  68. package/src/job/job.ts +2 -2
  69. package/src/metadata/metadata.ts +5 -3
  70. package/src/project/project.ts +12 -12
  71. package/src/task/task.ts +2 -2
  72. package/task/task.cjs +23 -7
  73. package/task/task.cjs.map +1 -1
  74. package/task/task.d.ts +3 -3
  75. package/task/task.js +23 -7
  76. package/task/task.js.map +1 -1
  77. package/type/type.cjs +5 -2
  78. package/type/type.cjs.map +1 -1
  79. package/type/type.d.ts +1 -1
  80. package/type/type.js +5 -2
  81. package/type/type.js.map +1 -1
  82. package/user/user.cjs +35 -13
  83. package/user/user.cjs.map +1 -1
  84. package/user/user.d.ts +1 -1
  85. package/user/user.js +35 -13
  86. package/user/user.js.map +1 -1
  87. package/chunk-3TENYKS7.js +0 -46
  88. package/chunk-RHHRF25R.cjs +0 -46
  89. package/chunk-RHHRF25R.cjs.map +0 -1
@@ -1,11 +1,14 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
2
2
 
3
- var _chunkRHHRF25Rcjs = require('../chunk-RHHRF25R.cjs');
3
+ var _chunkIUEU2LYCcjs = require('../chunk-IUEU2LYC.cjs');
4
4
 
5
5
  // src/accounting/accounting.ts
6
6
  var _reactquery = require('react-query');
7
7
  var getAccountServerNamespace = (options, signal) => {
8
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, { url: `/account-server/namespace`, method: "get", signal }, options);
8
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
9
+ { url: `/account-server/namespace`, method: "get", signal },
10
+ options
11
+ );
9
12
  };
10
13
  var getGetAccountServerNamespaceQueryKey = () => [
11
14
  `/account-server/namespace`
@@ -19,7 +22,10 @@ var useGetAccountServerNamespace = (options) => {
19
22
  return query;
20
23
  };
21
24
  var getAccountServerRegistration = (options, signal) => {
22
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, { url: `/account-server/registration`, method: "get", signal }, options);
25
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
26
+ { url: `/account-server/registration`, method: "get", signal },
27
+ options
28
+ );
23
29
  };
24
30
  var getGetAccountServerRegistrationQueryKey = () => [
25
31
  `/account-server/registration`
@@ -33,7 +39,10 @@ var useGetAccountServerRegistration = (options) => {
33
39
  return query;
34
40
  };
35
41
  var getVersion = (options, signal) => {
36
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, { url: `/version`, method: "get", signal }, options);
42
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
43
+ { url: `/version`, method: "get", signal },
44
+ options
45
+ );
37
46
  };
38
47
  var getGetVersionQueryKey = () => [`/version`];
39
48
  var useGetVersion = (options) => {
@@ -42,7 +51,11 @@ var useGetVersion = (options) => {
42
51
  const queryFn = ({
43
52
  signal
44
53
  }) => getVersion(requestOptions, signal);
45
- const query = _reactquery.useQuery.call(void 0, queryKey, queryFn, queryOptions);
54
+ const query = _reactquery.useQuery.call(void 0,
55
+ queryKey,
56
+ queryFn,
57
+ queryOptions
58
+ );
46
59
  query.queryKey = queryKey;
47
60
  return query;
48
61
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/accounting/accounting.ts"],"names":[],"mappings":";;;;;AAUA;AA6BO,IAAM,4BAA4B,CACvC,SACA,WACG;AACH,SAAO,eACL,EAAE,KAAK,6BAA6B,QAAQ,OAAO,OAAO,GAC1D,OACF;AACF;AAEO,IAAM,uCAAuC,MAAM;AAAA,EACxD;AACF;AAOO,IAAM,+BAA+B,CAG1C,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,mBAAmB,WAAW,CAAC;AAErE,QAAM,WACJ,8CAAc,aAAY,qCAAqC;AAEjE,QAAM,UAEF,CAAC,EAAE,aAAa,0BAA0B,gBAAgB,MAAM;AAEpE,QAAM,QAAQ,SAIZ,UAAU,SAAS,YAAY;AAIjC,QAAM,WAAW;AAEjB,SAAO;AACT;AAOO,IAAM,+BAA+B,CAC1C,SACA,WACG;AACH,SAAO,eACL,EAAE,KAAK,gCAAgC,QAAQ,OAAO,OAAO,GAC7D,OACF;AACF;AAEO,IAAM,0CAA0C,MAAM;AAAA,EAC3D;AACF;AAOO,IAAM,kCAAkC,CAG7C,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,mBAAmB,WAAW,CAAC;AAErE,QAAM,WACJ,8CAAc,aAAY,wCAAwC;AAEpE,QAAM,UAEF,CAAC,EAAE,aAAa,6BAA6B,gBAAgB,MAAM;AAEvE,QAAM,QAAQ,SAIZ,UAAU,SAAS,YAAY;AAIjC,QAAM,WAAW;AAEjB,SAAO;AACT;AAKO,IAAM,aAAa,CACxB,SACA,WACG;AACH,SAAO,eACL,EAAE,KAAK,YAAY,QAAQ,OAAO,OAAO,GACzC,OACF;AACF;AAEO,IAAM,wBAAwB,MAAM,CAAC,UAAU;AAO/C,IAAM,gBAAgB,CAG3B,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,mBAAmB,WAAW,CAAC;AAErE,QAAM,WAAW,8CAAc,aAAY,sBAAsB;AAEjE,QAAM,UAAiE,CAAC;AAAA,IACtE;AAAA,QACI,WAAW,gBAAgB,MAAM;AAEvC,QAAM,QAAQ,SACZ,UACA,SACA,YACF;AAEA,QAAM,WAAW;AAEjB,SAAO;AACT","sourcesContent":["/**\n * Generated by orval v6.9.1 🍺\n * Do not edit manually.\n * Dataset Manager API\n * The Dataset Manager API service.\n\nA service that allows *registered* users to make **Datasets** and associated **Metadata** available to **Applications** and **Jobs** using **Projects** and **Files**.\n\n * OpenAPI spec version: 1.0\n */\nimport { useQuery } from \"react-query\";\nimport type {\n UseQueryOptions,\n QueryFunction,\n UseQueryResult,\n QueryKey,\n} from \"react-query\";\nimport type {\n AccountServerGetNamespaceResponse,\n DmError,\n AccountServerGetRegistrationResponse,\n VersionGetResponse,\n} from \"../data-manager-api.schemas\";\nimport { customInstance } from \".././custom-instance\";\nimport type { ErrorType } from \".././custom-instance\";\n\n// eslint-disable-next-line\ntype SecondParameter<T extends (...args: any) => any> = T extends (\n config: any,\n args: infer P\n) => any\n ? P\n : never;\n\n/**\n * If an Account Server is configured its namespace, e.g. `account-server`, is returned, otherwise an empty string is returned\n\n * @summary Gets the Account Server cluster namespace\n */\nexport const getAccountServerNamespace = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AccountServerGetNamespaceResponse>(\n { url: `/account-server/namespace`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetAccountServerNamespaceQueryKey = () => [\n `/account-server/namespace`,\n];\n\nexport type GetAccountServerNamespaceQueryResult = NonNullable<\n Awaited<ReturnType<typeof getAccountServerNamespace>>\n>;\nexport type GetAccountServerNamespaceQueryError = ErrorType<void | DmError>;\n\nexport const useGetAccountServerNamespace = <\n TData = Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getGetAccountServerNamespaceQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof getAccountServerNamespace>>\n > = ({ signal }) => getAccountServerNamespace(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * Returns our Account Server Registration information\n\n * @summary Gets the Data Manager Account Server Registration\n */\nexport const getAccountServerRegistration = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AccountServerGetRegistrationResponse>(\n { url: `/account-server/registration`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetAccountServerRegistrationQueryKey = () => [\n `/account-server/registration`,\n];\n\nexport type GetAccountServerRegistrationQueryResult = NonNullable<\n Awaited<ReturnType<typeof getAccountServerRegistration>>\n>;\nexport type GetAccountServerRegistrationQueryError = ErrorType<void | DmError>;\n\nexport const useGetAccountServerRegistration = <\n TData = Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getGetAccountServerRegistrationQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof getAccountServerRegistration>>\n > = ({ signal }) => getAccountServerRegistration(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * @summary Gets the Data Manager version that's running behind the API\n */\nexport const getVersion = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<VersionGetResponse>(\n { url: `/version`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetVersionQueryKey = () => [`/version`];\n\nexport type GetVersionQueryResult = NonNullable<\n Awaited<ReturnType<typeof getVersion>>\n>;\nexport type GetVersionQueryError = ErrorType<void | DmError>;\n\nexport const useGetVersion = <\n TData = Awaited<ReturnType<typeof getVersion>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getVersion>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetVersionQueryKey();\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getVersion>>> = ({\n signal,\n }) => getVersion(requestOptions, signal);\n\n const query = useQuery<Awaited<ReturnType<typeof getVersion>>, TError, TData>(\n queryKey,\n queryFn,\n queryOptions\n ) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryKey;\n\n return query;\n};\n"]}
1
+ {"version":3,"sources":["../../src/accounting/accounting.ts"],"names":[],"mappings":";;;;;AAUA,SAAS,gBAAgB;AA6BlB,IAAM,4BAA4B,CACvC,SACA,WACG;AACH,SAAO;AAAA,IACL,EAAE,KAAK,6BAA6B,QAAQ,OAAO,OAAO;AAAA,IAC1D;AAAA,EACF;AACF;AAEO,IAAM,uCAAuC,MAAM;AAAA,EACxD;AACF;AAOO,IAAM,+BAA+B,CAG1C,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,eAAe,IAAI,WAAW,CAAC;AAErE,QAAM,YACJ,6CAAc,aAAY,qCAAqC;AAEjE,QAAM,UAEF,CAAC,EAAE,OAAO,MAAM,0BAA0B,gBAAgB,MAAM;AAEpE,QAAM,QAAQ,SAIZ,UAAU,SAAS,YAAY;AAIjC,QAAM,WAAW;AAEjB,SAAO;AACT;AAOO,IAAM,+BAA+B,CAC1C,SACA,WACG;AACH,SAAO;AAAA,IACL,EAAE,KAAK,gCAAgC,QAAQ,OAAO,OAAO;AAAA,IAC7D;AAAA,EACF;AACF;AAEO,IAAM,0CAA0C,MAAM;AAAA,EAC3D;AACF;AAOO,IAAM,kCAAkC,CAG7C,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,eAAe,IAAI,WAAW,CAAC;AAErE,QAAM,YACJ,6CAAc,aAAY,wCAAwC;AAEpE,QAAM,UAEF,CAAC,EAAE,OAAO,MAAM,6BAA6B,gBAAgB,MAAM;AAEvE,QAAM,QAAQ,SAIZ,UAAU,SAAS,YAAY;AAIjC,QAAM,WAAW;AAEjB,SAAO;AACT;AAKO,IAAM,aAAa,CACxB,SACA,WACG;AACH,SAAO;AAAA,IACL,EAAE,KAAK,YAAY,QAAQ,OAAO,OAAO;AAAA,IACzC;AAAA,EACF;AACF;AAEO,IAAM,wBAAwB,MAAM,CAAC,UAAU;AAO/C,IAAM,gBAAgB,CAG3B,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,eAAe,IAAI,WAAW,CAAC;AAErE,QAAM,YAAW,6CAAc,aAAY,sBAAsB;AAEjE,QAAM,UAAiE,CAAC;AAAA,IACtE;AAAA,EACF,MAAM,WAAW,gBAAgB,MAAM;AAEvC,QAAM,QAAQ;AAAA,IACZ;AAAA,IACA;AAAA,IACA;AAAA,EACF;AAEA,QAAM,WAAW;AAEjB,SAAO;AACT","sourcesContent":["/**\n * Generated by orval v6.9.1 🍺\n * Do not edit manually.\n * Dataset Manager API\n * The Dataset Manager API service.\n\nA service that allows *registered* users to make **Datasets** and associated **Metadata** available to **Applications** and **Jobs** using **Projects** and **Files**.\n\n * OpenAPI spec version: 1.0\n */\nimport { useQuery } from \"react-query\";\nimport type {\n UseQueryOptions,\n QueryFunction,\n UseQueryResult,\n QueryKey,\n} from \"react-query\";\nimport type {\n AccountServerGetNamespaceResponse,\n DmError,\n AccountServerGetRegistrationResponse,\n VersionGetResponse,\n} from \"../data-manager-api.schemas\";\nimport { customInstance } from \".././custom-instance\";\nimport type { ErrorType } from \".././custom-instance\";\n\n// eslint-disable-next-line\ntype SecondParameter<T extends (...args: any) => any> = T extends (\n config: any,\n args: infer P\n) => any\n ? P\n : never;\n\n/**\n * If an Account Server is configured its namespace, e.g. `account-server`, is returned, otherwise an empty string is returned\n\n * @summary Gets the Account Server cluster namespace\n */\nexport const getAccountServerNamespace = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AccountServerGetNamespaceResponse>(\n { url: `/account-server/namespace`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetAccountServerNamespaceQueryKey = () => [\n `/account-server/namespace`,\n];\n\nexport type GetAccountServerNamespaceQueryResult = NonNullable<\n Awaited<ReturnType<typeof getAccountServerNamespace>>\n>;\nexport type GetAccountServerNamespaceQueryError = ErrorType<void | DmError>;\n\nexport const useGetAccountServerNamespace = <\n TData = Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getGetAccountServerNamespaceQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof getAccountServerNamespace>>\n > = ({ signal }) => getAccountServerNamespace(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * Returns our Account Server Registration information\n\n * @summary Gets the Data Manager Account Server Registration\n */\nexport const getAccountServerRegistration = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AccountServerGetRegistrationResponse>(\n { url: `/account-server/registration`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetAccountServerRegistrationQueryKey = () => [\n `/account-server/registration`,\n];\n\nexport type GetAccountServerRegistrationQueryResult = NonNullable<\n Awaited<ReturnType<typeof getAccountServerRegistration>>\n>;\nexport type GetAccountServerRegistrationQueryError = ErrorType<void | DmError>;\n\nexport const useGetAccountServerRegistration = <\n TData = Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getGetAccountServerRegistrationQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof getAccountServerRegistration>>\n > = ({ signal }) => getAccountServerRegistration(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * @summary Gets the Data Manager version that's running behind the API\n */\nexport const getVersion = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<VersionGetResponse>(\n { url: `/version`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetVersionQueryKey = () => [`/version`];\n\nexport type GetVersionQueryResult = NonNullable<\n Awaited<ReturnType<typeof getVersion>>\n>;\nexport type GetVersionQueryError = ErrorType<void | DmError>;\n\nexport const useGetVersion = <\n TData = Awaited<ReturnType<typeof getVersion>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getVersion>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetVersionQueryKey();\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getVersion>>> = ({\n signal,\n }) => getVersion(requestOptions, signal);\n\n const query = useQuery<Awaited<ReturnType<typeof getVersion>>, TError, TData>(\n queryKey,\n queryFn,\n queryOptions\n ) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryKey;\n\n return query;\n};\n"]}
@@ -1,5 +1,5 @@
1
1
  import { UseQueryOptions, QueryKey, UseQueryResult } from 'react-query';
2
- import { bz as customInstance, bt as AccountServerGetNamespaceResponse, bA as ErrorType, bv as DmError, bu as AccountServerGetRegistrationResponse, aP as VersionGetResponse } from '../custom-instance-b2f7dca1.js';
2
+ import { bB as customInstance, bv as AccountServerGetNamespaceResponse, bC as ErrorType, bx as DmError, bw as AccountServerGetRegistrationResponse, aQ as VersionGetResponse } from '../custom-instance-3a73945d.js';
3
3
  import 'axios';
4
4
 
5
5
  declare type SecondParameter<T extends (...args: any) => any> = T extends (config: any, args: infer P) => any ? P : never;
@@ -1,11 +1,14 @@
1
1
  import {
2
2
  customInstance
3
- } from "../chunk-3TENYKS7.js";
3
+ } from "../chunk-3O5KIRV4.js";
4
4
 
5
5
  // src/accounting/accounting.ts
6
6
  import { useQuery } from "react-query";
7
7
  var getAccountServerNamespace = (options, signal) => {
8
- return customInstance({ url: `/account-server/namespace`, method: "get", signal }, options);
8
+ return customInstance(
9
+ { url: `/account-server/namespace`, method: "get", signal },
10
+ options
11
+ );
9
12
  };
10
13
  var getGetAccountServerNamespaceQueryKey = () => [
11
14
  `/account-server/namespace`
@@ -19,7 +22,10 @@ var useGetAccountServerNamespace = (options) => {
19
22
  return query;
20
23
  };
21
24
  var getAccountServerRegistration = (options, signal) => {
22
- return customInstance({ url: `/account-server/registration`, method: "get", signal }, options);
25
+ return customInstance(
26
+ { url: `/account-server/registration`, method: "get", signal },
27
+ options
28
+ );
23
29
  };
24
30
  var getGetAccountServerRegistrationQueryKey = () => [
25
31
  `/account-server/registration`
@@ -33,7 +39,10 @@ var useGetAccountServerRegistration = (options) => {
33
39
  return query;
34
40
  };
35
41
  var getVersion = (options, signal) => {
36
- return customInstance({ url: `/version`, method: "get", signal }, options);
42
+ return customInstance(
43
+ { url: `/version`, method: "get", signal },
44
+ options
45
+ );
37
46
  };
38
47
  var getGetVersionQueryKey = () => [`/version`];
39
48
  var useGetVersion = (options) => {
@@ -42,7 +51,11 @@ var useGetVersion = (options) => {
42
51
  const queryFn = ({
43
52
  signal
44
53
  }) => getVersion(requestOptions, signal);
45
- const query = useQuery(queryKey, queryFn, queryOptions);
54
+ const query = useQuery(
55
+ queryKey,
56
+ queryFn,
57
+ queryOptions
58
+ );
46
59
  query.queryKey = queryKey;
47
60
  return query;
48
61
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/accounting/accounting.ts"],"sourcesContent":["/**\n * Generated by orval v6.9.1 🍺\n * Do not edit manually.\n * Dataset Manager API\n * The Dataset Manager API service.\n\nA service that allows *registered* users to make **Datasets** and associated **Metadata** available to **Applications** and **Jobs** using **Projects** and **Files**.\n\n * OpenAPI spec version: 1.0\n */\nimport { useQuery } from \"react-query\";\nimport type {\n UseQueryOptions,\n QueryFunction,\n UseQueryResult,\n QueryKey,\n} from \"react-query\";\nimport type {\n AccountServerGetNamespaceResponse,\n DmError,\n AccountServerGetRegistrationResponse,\n VersionGetResponse,\n} from \"../data-manager-api.schemas\";\nimport { customInstance } from \".././custom-instance\";\nimport type { ErrorType } from \".././custom-instance\";\n\n// eslint-disable-next-line\ntype SecondParameter<T extends (...args: any) => any> = T extends (\n config: any,\n args: infer P\n) => any\n ? P\n : never;\n\n/**\n * If an Account Server is configured its namespace, e.g. `account-server`, is returned, otherwise an empty string is returned\n\n * @summary Gets the Account Server cluster namespace\n */\nexport const getAccountServerNamespace = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AccountServerGetNamespaceResponse>(\n { url: `/account-server/namespace`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetAccountServerNamespaceQueryKey = () => [\n `/account-server/namespace`,\n];\n\nexport type GetAccountServerNamespaceQueryResult = NonNullable<\n Awaited<ReturnType<typeof getAccountServerNamespace>>\n>;\nexport type GetAccountServerNamespaceQueryError = ErrorType<void | DmError>;\n\nexport const useGetAccountServerNamespace = <\n TData = Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getGetAccountServerNamespaceQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof getAccountServerNamespace>>\n > = ({ signal }) => getAccountServerNamespace(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * Returns our Account Server Registration information\n\n * @summary Gets the Data Manager Account Server Registration\n */\nexport const getAccountServerRegistration = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AccountServerGetRegistrationResponse>(\n { url: `/account-server/registration`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetAccountServerRegistrationQueryKey = () => [\n `/account-server/registration`,\n];\n\nexport type GetAccountServerRegistrationQueryResult = NonNullable<\n Awaited<ReturnType<typeof getAccountServerRegistration>>\n>;\nexport type GetAccountServerRegistrationQueryError = ErrorType<void | DmError>;\n\nexport const useGetAccountServerRegistration = <\n TData = Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getGetAccountServerRegistrationQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof getAccountServerRegistration>>\n > = ({ signal }) => getAccountServerRegistration(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * @summary Gets the Data Manager version that's running behind the API\n */\nexport const getVersion = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<VersionGetResponse>(\n { url: `/version`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetVersionQueryKey = () => [`/version`];\n\nexport type GetVersionQueryResult = NonNullable<\n Awaited<ReturnType<typeof getVersion>>\n>;\nexport type GetVersionQueryError = ErrorType<void | DmError>;\n\nexport const useGetVersion = <\n TData = Awaited<ReturnType<typeof getVersion>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getVersion>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetVersionQueryKey();\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getVersion>>> = ({\n signal,\n }) => getVersion(requestOptions, signal);\n\n const query = useQuery<Awaited<ReturnType<typeof getVersion>>, TError, TData>(\n queryKey,\n queryFn,\n queryOptions\n ) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryKey;\n\n return query;\n};\n"],"mappings":";;;;;AAUA;AA6BO,IAAM,4BAA4B,CACvC,SACA,WACG;AACH,SAAO,eACL,EAAE,KAAK,6BAA6B,QAAQ,OAAO,OAAO,GAC1D,OACF;AACF;AAEO,IAAM,uCAAuC,MAAM;AAAA,EACxD;AACF;AAOO,IAAM,+BAA+B,CAG1C,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,mBAAmB,WAAW,CAAC;AAErE,QAAM,WACJ,8CAAc,aAAY,qCAAqC;AAEjE,QAAM,UAEF,CAAC,EAAE,aAAa,0BAA0B,gBAAgB,MAAM;AAEpE,QAAM,QAAQ,SAIZ,UAAU,SAAS,YAAY;AAIjC,QAAM,WAAW;AAEjB,SAAO;AACT;AAOO,IAAM,+BAA+B,CAC1C,SACA,WACG;AACH,SAAO,eACL,EAAE,KAAK,gCAAgC,QAAQ,OAAO,OAAO,GAC7D,OACF;AACF;AAEO,IAAM,0CAA0C,MAAM;AAAA,EAC3D;AACF;AAOO,IAAM,kCAAkC,CAG7C,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,mBAAmB,WAAW,CAAC;AAErE,QAAM,WACJ,8CAAc,aAAY,wCAAwC;AAEpE,QAAM,UAEF,CAAC,EAAE,aAAa,6BAA6B,gBAAgB,MAAM;AAEvE,QAAM,QAAQ,SAIZ,UAAU,SAAS,YAAY;AAIjC,QAAM,WAAW;AAEjB,SAAO;AACT;AAKO,IAAM,aAAa,CACxB,SACA,WACG;AACH,SAAO,eACL,EAAE,KAAK,YAAY,QAAQ,OAAO,OAAO,GACzC,OACF;AACF;AAEO,IAAM,wBAAwB,MAAM,CAAC,UAAU;AAO/C,IAAM,gBAAgB,CAG3B,YAO4D;AAC5D,QAAM,EAAE,OAAO,cAAc,SAAS,mBAAmB,WAAW,CAAC;AAErE,QAAM,WAAW,8CAAc,aAAY,sBAAsB;AAEjE,QAAM,UAAiE,CAAC;AAAA,IACtE;AAAA,QACI,WAAW,gBAAgB,MAAM;AAEvC,QAAM,QAAQ,SACZ,UACA,SACA,YACF;AAEA,QAAM,WAAW;AAEjB,SAAO;AACT;","names":[]}
1
+ {"version":3,"sources":["../../src/accounting/accounting.ts"],"sourcesContent":["/**\n * Generated by orval v6.9.1 🍺\n * Do not edit manually.\n * Dataset Manager API\n * The Dataset Manager API service.\n\nA service that allows *registered* users to make **Datasets** and associated **Metadata** available to **Applications** and **Jobs** using **Projects** and **Files**.\n\n * OpenAPI spec version: 1.0\n */\nimport { useQuery } from \"react-query\";\nimport type {\n UseQueryOptions,\n QueryFunction,\n UseQueryResult,\n QueryKey,\n} from \"react-query\";\nimport type {\n AccountServerGetNamespaceResponse,\n DmError,\n AccountServerGetRegistrationResponse,\n VersionGetResponse,\n} from \"../data-manager-api.schemas\";\nimport { customInstance } from \".././custom-instance\";\nimport type { ErrorType } from \".././custom-instance\";\n\n// eslint-disable-next-line\ntype SecondParameter<T extends (...args: any) => any> = T extends (\n config: any,\n args: infer P\n) => any\n ? P\n : never;\n\n/**\n * If an Account Server is configured its namespace, e.g. `account-server`, is returned, otherwise an empty string is returned\n\n * @summary Gets the Account Server cluster namespace\n */\nexport const getAccountServerNamespace = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AccountServerGetNamespaceResponse>(\n { url: `/account-server/namespace`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetAccountServerNamespaceQueryKey = () => [\n `/account-server/namespace`,\n];\n\nexport type GetAccountServerNamespaceQueryResult = NonNullable<\n Awaited<ReturnType<typeof getAccountServerNamespace>>\n>;\nexport type GetAccountServerNamespaceQueryError = ErrorType<void | DmError>;\n\nexport const useGetAccountServerNamespace = <\n TData = Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getGetAccountServerNamespaceQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof getAccountServerNamespace>>\n > = ({ signal }) => getAccountServerNamespace(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof getAccountServerNamespace>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * Returns our Account Server Registration information\n\n * @summary Gets the Data Manager Account Server Registration\n */\nexport const getAccountServerRegistration = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AccountServerGetRegistrationResponse>(\n { url: `/account-server/registration`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetAccountServerRegistrationQueryKey = () => [\n `/account-server/registration`,\n];\n\nexport type GetAccountServerRegistrationQueryResult = NonNullable<\n Awaited<ReturnType<typeof getAccountServerRegistration>>\n>;\nexport type GetAccountServerRegistrationQueryError = ErrorType<void | DmError>;\n\nexport const useGetAccountServerRegistration = <\n TData = Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getGetAccountServerRegistrationQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof getAccountServerRegistration>>\n > = ({ signal }) => getAccountServerRegistration(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof getAccountServerRegistration>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * @summary Gets the Data Manager version that's running behind the API\n */\nexport const getVersion = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<VersionGetResponse>(\n { url: `/version`, method: \"get\", signal },\n options\n );\n};\n\nexport const getGetVersionQueryKey = () => [`/version`];\n\nexport type GetVersionQueryResult = NonNullable<\n Awaited<ReturnType<typeof getVersion>>\n>;\nexport type GetVersionQueryError = ErrorType<void | DmError>;\n\nexport const useGetVersion = <\n TData = Awaited<ReturnType<typeof getVersion>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof getVersion>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetVersionQueryKey();\n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getVersion>>> = ({\n signal,\n }) => getVersion(requestOptions, signal);\n\n const query = useQuery<Awaited<ReturnType<typeof getVersion>>, TError, TData>(\n queryKey,\n queryFn,\n queryOptions\n ) as UseQueryResult<TData, TError> & { queryKey: QueryKey };\n\n query.queryKey = queryKey;\n\n return query;\n};\n"],"mappings":";;;;;AAUA,SAAS,gBAAgB;AA6BlB,IAAM,4BAA4B,CACvC,SACA,WACG;AACH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AAgB,MAAM;AAEvC,QAAM,QAAQ;AAAA,IACZ;AAAA,IACA;AAAA,IACA;AAAA,EACF;AAEA,QAAM,WAAW;AAEjB,SAAO;AACT;","names":[]}
package/admin/admin.cjs CHANGED
@@ -1,11 +1,14 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
2
2
 
3
- var _chunkRHHRF25Rcjs = require('../chunk-RHHRF25R.cjs');
3
+ var _chunkIUEU2LYCcjs = require('../chunk-IUEU2LYC.cjs');
4
4
 
5
5
  // src/admin/admin.ts
6
6
  var _reactquery = require('react-query');
7
7
  var adminGetServiceErrors = (params, options, signal) => {
8
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, { url: `/admin/service-error`, method: "get", params, signal }, options);
8
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
9
+ { url: `/admin/service-error`, method: "get", params, signal },
10
+ options
11
+ );
9
12
  };
10
13
  var getAdminGetServiceErrorsQueryKey = (params) => [`/admin/service-error`, ...params ? [params] : []];
11
14
  var useAdminGetServiceErrors = (params, options) => {
@@ -17,7 +20,10 @@ var useAdminGetServiceErrors = (params, options) => {
17
20
  return query;
18
21
  };
19
22
  var adminPatchServiceError = (errorId, options) => {
20
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, { url: `/admin/service-error/${errorId}`, method: "patch" }, options);
23
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
24
+ { url: `/admin/service-error/${errorId}`, method: "patch" },
25
+ options
26
+ );
21
27
  };
22
28
  var useAdminPatchServiceError = (options) => {
23
29
  const { mutation: mutationOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
@@ -28,7 +34,10 @@ var useAdminPatchServiceError = (options) => {
28
34
  return _reactquery.useMutation.call(void 0, mutationFn, mutationOptions);
29
35
  };
30
36
  var adminDeleteServiceError = (errorId, options) => {
31
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, { url: `/admin/service-error/${errorId}`, method: "delete" }, options);
37
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
38
+ { url: `/admin/service-error/${errorId}`, method: "delete" },
39
+ options
40
+ );
32
41
  };
33
42
  var useAdminDeleteServiceError = (options) => {
34
43
  const { mutation: mutationOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
@@ -39,7 +48,10 @@ var useAdminDeleteServiceError = (options) => {
39
48
  return _reactquery.useMutation.call(void 0, mutationFn, mutationOptions);
40
49
  };
41
50
  var adminPutUser = (userId, options) => {
42
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, { url: `/admin/user/${userId}`, method: "put" }, options);
51
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
52
+ { url: `/admin/user/${userId}`, method: "put" },
53
+ options
54
+ );
43
55
  };
44
56
  var useAdminPutUser = (options) => {
45
57
  const { mutation: mutationOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
@@ -50,7 +62,10 @@ var useAdminPutUser = (options) => {
50
62
  return _reactquery.useMutation.call(void 0, mutationFn, mutationOptions);
51
63
  };
52
64
  var adminDeleteUser = (userId, options) => {
53
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, { url: `/admin/user/${userId}`, method: "delete" }, options);
65
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
66
+ { url: `/admin/user/${userId}`, method: "delete" },
67
+ options
68
+ );
54
69
  };
55
70
  var useAdminDeleteUser = (options) => {
56
71
  const { mutation: mutationOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
@@ -65,12 +80,15 @@ var adminPatchUser = (userId, userPatchBodyBody, options) => {
65
80
  if (userPatchBodyBody.suspend_message !== void 0) {
66
81
  formData.append("suspend_message", userPatchBodyBody.suspend_message);
67
82
  }
68
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, {
69
- url: `/admin/user/${userId}`,
70
- method: "patch",
71
- headers: { "Content-Type": "multipart/form-data" },
72
- data: formData
73
- }, options);
83
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
84
+ {
85
+ url: `/admin/user/${userId}`,
86
+ method: "patch",
87
+ headers: { "Content-Type": "multipart/form-data" },
88
+ data: formData
89
+ },
90
+ options
91
+ );
74
92
  };
75
93
  var useAdminPatchUser = (options) => {
76
94
  const { mutation: mutationOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
@@ -80,6 +98,21 @@ var useAdminPatchUser = (options) => {
80
98
  };
81
99
  return _reactquery.useMutation.call(void 0, mutationFn, mutationOptions);
82
100
  };
101
+ var adminGetJobManifests = (options, signal) => {
102
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
103
+ { url: `/admin/job-manifest`, method: "get", signal },
104
+ options
105
+ );
106
+ };
107
+ var getAdminGetJobManifestsQueryKey = () => [`/admin/job-manifest`];
108
+ var useAdminGetJobManifests = (options) => {
109
+ const { query: queryOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
110
+ const queryKey = _nullishCoalesce((queryOptions == null ? void 0 : queryOptions.queryKey), () => ( getAdminGetJobManifestsQueryKey()));
111
+ const queryFn = ({ signal }) => adminGetJobManifests(requestOptions, signal);
112
+ const query = _reactquery.useQuery.call(void 0, queryKey, queryFn, queryOptions);
113
+ query.queryKey = queryKey;
114
+ return query;
115
+ };
83
116
  var adminJobManifestPut = (jobManifestPutBodyBody, options) => {
84
117
  const formData = new FormData();
85
118
  formData.append("url", jobManifestPutBodyBody.url);
@@ -89,12 +122,15 @@ var adminJobManifestPut = (jobManifestPutBodyBody, options) => {
89
122
  if (jobManifestPutBodyBody.params !== void 0) {
90
123
  formData.append("params", jobManifestPutBodyBody.params);
91
124
  }
92
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, {
93
- url: `/admin/job-manifest`,
94
- method: "put",
95
- headers: { "Content-Type": "multipart/form-data" },
96
- data: formData
97
- }, options);
125
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
126
+ {
127
+ url: `/admin/job-manifest`,
128
+ method: "put",
129
+ headers: { "Content-Type": "multipart/form-data" },
130
+ data: formData
131
+ },
132
+ options
133
+ );
98
134
  };
99
135
  var useAdminJobManifestPut = (options) => {
100
136
  const { mutation: mutationOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
@@ -107,12 +143,15 @@ var useAdminJobManifestPut = (options) => {
107
143
  var adminJobManifestLoad = (jobManifestLoadPutBodyBody, options) => {
108
144
  const formData = new FormData();
109
145
  formData.append("purge", jobManifestLoadPutBodyBody.purge.toString());
110
- return _chunkRHHRF25Rcjs.customInstance.call(void 0, {
111
- url: `/admin/job-manifest/load`,
112
- method: "put",
113
- headers: { "Content-Type": "multipart/form-data" },
114
- data: formData
115
- }, options);
146
+ return _chunkIUEU2LYCcjs.customInstance.call(void 0,
147
+ {
148
+ url: `/admin/job-manifest/load`,
149
+ method: "put",
150
+ headers: { "Content-Type": "multipart/form-data" },
151
+ data: formData
152
+ },
153
+ options
154
+ );
116
155
  };
117
156
  var useAdminJobManifestLoad = (options) => {
118
157
  const { mutation: mutationOptions, request: requestOptions } = _nullishCoalesce(options, () => ( {}));
@@ -140,5 +179,8 @@ var useAdminJobManifestLoad = (options) => {
140
179
 
141
180
 
142
181
 
143
- exports.adminDeleteServiceError = adminDeleteServiceError; exports.adminDeleteUser = adminDeleteUser; exports.adminGetServiceErrors = adminGetServiceErrors; exports.adminJobManifestLoad = adminJobManifestLoad; exports.adminJobManifestPut = adminJobManifestPut; exports.adminPatchServiceError = adminPatchServiceError; exports.adminPatchUser = adminPatchUser; exports.adminPutUser = adminPutUser; exports.getAdminGetServiceErrorsQueryKey = getAdminGetServiceErrorsQueryKey; exports.useAdminDeleteServiceError = useAdminDeleteServiceError; exports.useAdminDeleteUser = useAdminDeleteUser; exports.useAdminGetServiceErrors = useAdminGetServiceErrors; exports.useAdminJobManifestLoad = useAdminJobManifestLoad; exports.useAdminJobManifestPut = useAdminJobManifestPut; exports.useAdminPatchServiceError = useAdminPatchServiceError; exports.useAdminPatchUser = useAdminPatchUser; exports.useAdminPutUser = useAdminPutUser;
182
+
183
+
184
+
185
+ exports.adminDeleteServiceError = adminDeleteServiceError; exports.adminDeleteUser = adminDeleteUser; exports.adminGetJobManifests = adminGetJobManifests; exports.adminGetServiceErrors = adminGetServiceErrors; exports.adminJobManifestLoad = adminJobManifestLoad; exports.adminJobManifestPut = adminJobManifestPut; exports.adminPatchServiceError = adminPatchServiceError; exports.adminPatchUser = adminPatchUser; exports.adminPutUser = adminPutUser; exports.getAdminGetJobManifestsQueryKey = getAdminGetJobManifestsQueryKey; exports.getAdminGetServiceErrorsQueryKey = getAdminGetServiceErrorsQueryKey; exports.useAdminDeleteServiceError = useAdminDeleteServiceError; exports.useAdminDeleteUser = useAdminDeleteUser; exports.useAdminGetJobManifests = useAdminGetJobManifests; exports.useAdminGetServiceErrors = useAdminGetServiceErrors; exports.useAdminJobManifestLoad = useAdminJobManifestLoad; exports.useAdminJobManifestPut = useAdminJobManifestPut; exports.useAdminPatchServiceError = useAdminPatchServiceError; exports.useAdminPatchUser = useAdminPatchUser; exports.useAdminPutUser = useAdminPutUser;
144
186
  //# sourceMappingURL=admin.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/admin/admin.ts"],"names":[],"mappings":";;;;;AAUA;AAqCO,IAAM,wBAAwB,CACnC,QACA,SACA,WACG;AACH,SAAO,eACL,EAAE,KAAK,wBAAwB,QAAQ,OAAO,QAAQ,OAAO,GAC7D,OACF;AACF;AAEO,IAAM,mCAAmC,CAC9C,WACG,CAAC,wBAAwB,GAAI,SAAS,CAAC,MAAM,IAAI,CAAC,CAAE;AAOlD,IAAM,2BAA2B,CAItC,QACA,YAQ2D;AAC3D,QAAM,EAAE,OAAO,cAAc,SAAS,mBAAmB,WAAW,CAAC;AAErE,QAAM,WACJ,8CAAc,aAAY,iCAAiC,MAAM;AAEnE,QAAM,UAEF,CAAC,EAAE,aAAa,sBAAsB,QAAQ,gBAAgB,MAAM;AAExE,QAAM,QAAQ,SAIZ,UAAU,SAAS,Y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AAiB,SAAS,mBAAmB,WAAW,CAAC;AAE3E,QAAM,aAGF,CAAC,UAAU;AACb,UAAM,EAAE,SAAS,SAAS,CAAC;AAE3B,WAAO,oBAAoB,MAAM,cAAc;AAAA,EACjD;AAEA,SAAO,YAKL,YAAY,eAAe;AAC/B;AAQO,IAAM,uBAAuB,CAClC,4BACA,YACG;AACH,QAAM,WAAW,IAAI,SAAS;AAC9B,WAAS,OAAO,SAAS,2BAA2B,MAAM,SAAS,CAAC;AAEpE,SAAO,eACL;AAAA,IACE,KAAK;AAAA,IACL,QAAQ;AAAA,IACR,SAAS,EAAE,gBAAgB,sBAAsB;AAAA,IACjD,MAAM;AAAA,EACR,GACA,OACF;AACF;AAQO,IAAM,0BAA0B,CAGrC,YAQI;AACJ,QAAM,EAAE,UAAU,iBAAiB,SAAS,mBAAmB,WAAW,CAAC;AAE3E,QAAM,aAGF,CAAC,UAAU;AACb,UAAM,EAAE,SAAS,SAAS,CAAC;AAE3B,WAAO,qBAAqB,MAAM,cAAc;AAAA,EAClD;AAEA,SAAO,YAKL,YAAY,eAAe;AAC/B","sourcesContent":["/**\n * Generated by orval v6.9.1 🍺\n * Do not edit manually.\n * Dataset Manager API\n * The Dataset Manager API service.\n\nA service that allows *registered* users to make **Datasets** and associated **Metadata** available to **Applications** and **Jobs** using **Projects** and **Files**.\n\n * OpenAPI spec version: 1.0\n */\nimport { useQuery, useMutation } from \"react-query\";\nimport type {\n UseQueryOptions,\n UseMutationOptions,\n QueryFunction,\n MutationFunction,\n UseQueryResult,\n QueryKey,\n} from \"react-query\";\nimport type {\n ServiceErrorsGetResponse,\n DmError,\n AdminGetServiceErrorsParams,\n AdminUserPutResponse,\n UserPatchBodyBody,\n AdminJobManifestLoadPutResponse,\n JobManifestPutBodyBody,\n JobManifestLoadPutBodyBody,\n} from \"../data-manager-api.schemas\";\nimport { customInstance } from \".././custom-instance\";\nimport type { ErrorType } from \".././custom-instance\";\n\n// eslint-disable-next-line\ntype SecondParameter<T extends (...args: any) => any> = T extends (\n config: any,\n args: infer P\n) => any\n ? P\n : never;\n\n/**\n * Displays the existing Service Errors, which can also include acknowledged errors, normally excluded from the list.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Gets Service Errors\n */\nexport const adminGetServiceErrors = (\n params?: AdminGetServiceErrorsParams,\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<ServiceErrorsGetResponse>(\n { url: `/admin/service-error`, method: \"get\", params, signal },\n options\n );\n};\n\nexport const getAdminGetServiceErrorsQueryKey = (\n params?: AdminGetServiceErrorsParams\n) => [`/admin/service-error`, ...(params ? [params] : [])];\n\nexport type AdminGetServiceErrorsQueryResult = NonNullable<\n Awaited<ReturnType<typeof adminGetServiceErrors>>\n>;\nexport type AdminGetServiceErrorsQueryError = ErrorType<void | DmError>;\n\nexport const useAdminGetServiceErrors = <\n TData = Awaited<ReturnType<typeof adminGetServiceErrors>>,\n TError = ErrorType<void | DmError>\n>(\n params?: AdminGetServiceErrorsParams,\n options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof adminGetServiceErrors>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n }\n): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getAdminGetServiceErrorsQueryKey(params);\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof adminGetServiceErrors>>\n > = ({ signal }) => adminGetServiceErrors(params, requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof adminGetServiceErrors>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * Used primarily to 'Acknowledge' but not delete a Service Error.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Patches a Service Error\n */\nexport const adminPatchServiceError = (\n errorId: number,\n options?: SecondParameter<typeof customInstance>\n) => {\n return customInstance<void>(\n { url: `/admin/service-error/${errorId}`, method: \"patch\" },\n options\n );\n};\n\nexport type AdminPatchServiceErrorMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminPatchServiceError>>\n>;\n\nexport type AdminPatchServiceErrorMutationError = ErrorType<DmError>;\n\nexport const useAdminPatchServiceError = <\n TError = ErrorType<DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminPatchServiceError>>,\n TError,\n { errorId: number },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminPatchServiceError>>,\n { errorId: number }\n > = (props) => {\n const { errorId } = props ?? {};\n\n return adminPatchServiceError(errorId, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminPatchServiceError>>,\n TError,\n { errorId: number },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * Deletes an existing Service Error.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Deletes a Service Error\n */\nexport const adminDeleteServiceError = (\n errorId: number,\n options?: SecondParameter<typeof customInstance>\n) => {\n return customInstance<void>(\n { url: `/admin/service-error/${errorId}`, method: \"delete\" },\n options\n );\n};\n\nexport type AdminDeleteServiceErrorMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminDeleteServiceError>>\n>;\n\nexport type AdminDeleteServiceErrorMutationError = ErrorType<DmError>;\n\nexport const useAdminDeleteServiceError = <\n TError = ErrorType<DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminDeleteServiceError>>,\n TError,\n { errorId: number },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminDeleteServiceError>>,\n { errorId: number }\n > = (props) => {\n const { errorId } = props ?? {};\n\n return adminDeleteServiceError(errorId, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminDeleteServiceError>>,\n TError,\n { errorId: number },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * This method adds a user to the Data Manager service. The user is authenticated via a keycloak server but will need an initialised account before they can create Datasets or Projects.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Prepares a user account in the Data Manager service\n */\nexport const adminPutUser = (\n userId: string,\n options?: SecondParameter<typeof customInstance>\n) => {\n return customInstance<AdminUserPutResponse>(\n { url: `/admin/user/${userId}`, method: \"put\" },\n options\n );\n};\n\nexport type AdminPutUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminPutUser>>\n>;\n\nexport type AdminPutUserMutationError = ErrorType<void | DmError>;\n\nexport const useAdminPutUser = <\n TError = ErrorType<void | DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminPutUser>>,\n TError,\n { userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminPutUser>>,\n { userId: string }\n > = (props) => {\n const { userId } = props ?? {};\n\n return adminPutUser(userId, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminPutUser>>,\n TError,\n { userId: string },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * Deletes a user account, along with all the user's Datasets\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Deletes a user account\n */\nexport const adminDeleteUser = (\n userId: string,\n options?: SecondParameter<typeof customInstance>\n) => {\n return customInstance<void>(\n { url: `/admin/user/${userId}`, method: \"delete\" },\n options\n );\n};\n\nexport type AdminDeleteUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminDeleteUser>>\n>;\n\nexport type AdminDeleteUserMutationError = ErrorType<DmError>;\n\nexport const useAdminDeleteUser = <\n TError = ErrorType<DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminDeleteUser>>,\n TError,\n { userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminDeleteUser>>,\n { userId: string }\n > = (props) => {\n const { userId } = props ?? {};\n\n return adminDeleteUser(userId, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminDeleteUser>>,\n TError,\n { userId: string },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * Patches a user record, typically to suspend or re-enable a user account\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Patch a given user\n */\nexport const adminPatchUser = (\n userId: string,\n userPatchBodyBody: UserPatchBodyBody,\n options?: SecondParameter<typeof customInstance>\n) => {\n const formData = new FormData();\n if (userPatchBodyBody.suspend_message !== undefined) {\n formData.append(\"suspend_message\", userPatchBodyBody.suspend_message);\n }\n\n return customInstance<void>(\n {\n url: `/admin/user/${userId}`,\n method: \"patch\",\n headers: { \"Content-Type\": \"multipart/form-data\" },\n data: formData,\n },\n options\n );\n};\n\nexport type AdminPatchUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminPatchUser>>\n>;\nexport type AdminPatchUserMutationBody = UserPatchBodyBody;\nexport type AdminPatchUserMutationError = ErrorType<DmError>;\n\nexport const useAdminPatchUser = <\n TError = ErrorType<DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminPatchUser>>,\n TError,\n { userId: string; data: UserPatchBodyBody },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminPatchUser>>,\n { userId: string; data: UserPatchBodyBody }\n > = (props) => {\n const { userId, data } = props ?? {};\n\n return adminPatchUser(userId, data, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminPatchUser>>,\n TError,\n { userId: string; data: UserPatchBodyBody },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * This endpoint is used to add (or update an existing manifest). Manifests are the source of Job definitions. Once added the manifest is inspected and any Jobs it refers to are loaded.\n\nA limited number of manifest origins (URLs) are supported. At the moment we support basic GitHib and GitLab URLs, i.e. those that begin `https://raw.githubusercontent.com/` and `https://gitlab.com/api/v4/projects/`.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Adds a manifest and triggers the download of Job Definitions\n */\nexport const adminJobManifestPut = (\n jobManifestPutBodyBody: JobManifestPutBodyBody,\n options?: SecondParameter<typeof customInstance>\n) => {\n const formData = new FormData();\n formData.append(\"url\", jobManifestPutBodyBody.url);\n if (jobManifestPutBodyBody.header !== undefined) {\n formData.append(\"header\", jobManifestPutBodyBody.header);\n }\n if (jobManifestPutBodyBody.params !== undefined) {\n formData.append(\"params\", jobManifestPutBodyBody.params);\n }\n\n return customInstance<AdminJobManifestLoadPutResponse>(\n {\n url: `/admin/job-manifest`,\n method: \"put\",\n headers: { \"Content-Type\": \"multipart/form-data\" },\n data: formData,\n },\n options\n );\n};\n\nexport type AdminJobManifestPutMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminJobManifestPut>>\n>;\nexport type AdminJobManifestPutMutationBody = JobManifestPutBodyBody;\nexport type AdminJobManifestPutMutationError = ErrorType<void | DmError>;\n\nexport const useAdminJobManifestPut = <\n TError = ErrorType<void | DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminJobManifestPut>>,\n TError,\n { data: JobManifestPutBodyBody },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminJobManifestPut>>,\n { data: JobManifestPutBodyBody }\n > = (props) => {\n const { data } = props ?? {};\n\n return adminJobManifestPut(data, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminJobManifestPut>>,\n TError,\n { data: JobManifestPutBodyBody },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * This endpoint is used to trigger the Data Manager to re-inspect the internal Job **Manifest** table and download the manifests and reprocess the related job definitions. This is normally done by an administrator when the Manifest table has been modified or if external job definitions are known to have changed in the referenced repositories.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Trigger a download of known Job Definitions using the Manifest table\n */\nexport const adminJobManifestLoad = (\n jobManifestLoadPutBodyBody: JobManifestLoadPutBodyBody,\n options?: SecondParameter<typeof customInstance>\n) => {\n const formData = new FormData();\n formData.append(\"purge\", jobManifestLoadPutBodyBody.purge.toString());\n\n return customInstance<AdminJobManifestLoadPutResponse>(\n {\n url: `/admin/job-manifest/load`,\n method: \"put\",\n headers: { \"Content-Type\": \"multipart/form-data\" },\n data: formData,\n },\n options\n );\n};\n\nexport type AdminJobManifestLoadMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminJobManifestLoad>>\n>;\nexport type AdminJobManifestLoadMutationBody = JobManifestLoadPutBodyBody;\nexport type AdminJobManifestLoadMutationError = ErrorType<void | DmError>;\n\nexport const useAdminJobManifestLoad = <\n TError = ErrorType<void | DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminJobManifestLoad>>,\n TError,\n { data: JobManifestLoadPutBodyBody },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminJobManifestLoad>>,\n { data: JobManifestLoadPutBodyBody }\n > = (props) => {\n const { data } = props ?? {};\n\n return adminJobManifestLoad(data, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminJobManifestLoad>>,\n TError,\n { data: JobManifestLoadPutBodyBody },\n TContext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AAI,WAAW,CAAC;AAE3E,QAAM,aAGF,CAAC,UAAU;AACb,UAAM,EAAE,KAAK,IAAI,SAAS,CAAC;AAE3B,WAAO,oBAAoB,MAAM,cAAc;AAAA,EACjD;AAEA,SAAO,YAKL,YAAY,eAAe;AAC/B;AAQO,IAAM,uBAAuB,CAClC,4BACA,YACG;AACH,QAAM,WAAW,IAAI,SAAS;AAC9B,WAAS,OAAO,SAAS,2BAA2B,MAAM,SAAS,CAAC;AAEpE,SAAO;AAAA,IACL;AAAA,MACE,KAAK;AAAA,MACL,QAAQ;AAAA,MACR,SAAS,EAAE,gBAAgB,sBAAsB;AAAA,MACjD,MAAM;AAAA,IACR;AAAA,IACA;AAAA,EACF;AACF;AAQO,IAAM,0BAA0B,CAGrC,YAQI;AACJ,QAAM,EAAE,UAAU,iBAAiB,SAAS,eAAe,IAAI,WAAW,CAAC;AAE3E,QAAM,aAGF,CAAC,UAAU;AACb,UAAM,EAAE,KAAK,IAAI,SAAS,CAAC;AAE3B,WAAO,qBAAqB,MAAM,cAAc;AAAA,EAClD;AAEA,SAAO,YAKL,YAAY,eAAe;AAC/B","sourcesContent":["/**\n * Generated by orval v6.9.1 🍺\n * Do not edit manually.\n * Dataset Manager API\n * The Dataset Manager API service.\n\nA service that allows *registered* users to make **Datasets** and associated **Metadata** available to **Applications** and **Jobs** using **Projects** and **Files**.\n\n * OpenAPI spec version: 1.0\n */\nimport { useQuery, useMutation } from \"react-query\";\nimport type {\n UseQueryOptions,\n UseMutationOptions,\n QueryFunction,\n MutationFunction,\n UseQueryResult,\n QueryKey,\n} from \"react-query\";\nimport type {\n ServiceErrorsGetResponse,\n DmError,\n AdminGetServiceErrorsParams,\n AdminUserPutResponse,\n UserPatchBodyBody,\n AdminJobManifestGetResponse,\n AdminJobManifestLoadPutResponse,\n JobManifestPutBodyBody,\n JobManifestLoadPutBodyBody,\n} from \"../data-manager-api.schemas\";\nimport { customInstance } from \".././custom-instance\";\nimport type { ErrorType } from \".././custom-instance\";\n\n// eslint-disable-next-line\ntype SecondParameter<T extends (...args: any) => any> = T extends (\n config: any,\n args: infer P\n) => any\n ? P\n : never;\n\n/**\n * Displays the existing Service Errors, which can also include acknowledged errors, normally excluded from the list.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Gets Service Errors\n */\nexport const adminGetServiceErrors = (\n params?: AdminGetServiceErrorsParams,\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<ServiceErrorsGetResponse>(\n { url: `/admin/service-error`, method: \"get\", params, signal },\n options\n );\n};\n\nexport const getAdminGetServiceErrorsQueryKey = (\n params?: AdminGetServiceErrorsParams\n) => [`/admin/service-error`, ...(params ? [params] : [])];\n\nexport type AdminGetServiceErrorsQueryResult = NonNullable<\n Awaited<ReturnType<typeof adminGetServiceErrors>>\n>;\nexport type AdminGetServiceErrorsQueryError = ErrorType<void | DmError>;\n\nexport const useAdminGetServiceErrors = <\n TData = Awaited<ReturnType<typeof adminGetServiceErrors>>,\n TError = ErrorType<void | DmError>\n>(\n params?: AdminGetServiceErrorsParams,\n options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof adminGetServiceErrors>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n }\n): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey =\n queryOptions?.queryKey ?? getAdminGetServiceErrorsQueryKey(params);\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof adminGetServiceErrors>>\n > = ({ signal }) => adminGetServiceErrors(params, requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof adminGetServiceErrors>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * Used primarily to 'Acknowledge' but not delete a Service Error.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Patches a Service Error\n */\nexport const adminPatchServiceError = (\n errorId: number,\n options?: SecondParameter<typeof customInstance>\n) => {\n return customInstance<void>(\n { url: `/admin/service-error/${errorId}`, method: \"patch\" },\n options\n );\n};\n\nexport type AdminPatchServiceErrorMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminPatchServiceError>>\n>;\n\nexport type AdminPatchServiceErrorMutationError = ErrorType<DmError>;\n\nexport const useAdminPatchServiceError = <\n TError = ErrorType<DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminPatchServiceError>>,\n TError,\n { errorId: number },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminPatchServiceError>>,\n { errorId: number }\n > = (props) => {\n const { errorId } = props ?? {};\n\n return adminPatchServiceError(errorId, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminPatchServiceError>>,\n TError,\n { errorId: number },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * Deletes an existing Service Error.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Deletes a Service Error\n */\nexport const adminDeleteServiceError = (\n errorId: number,\n options?: SecondParameter<typeof customInstance>\n) => {\n return customInstance<void>(\n { url: `/admin/service-error/${errorId}`, method: \"delete\" },\n options\n );\n};\n\nexport type AdminDeleteServiceErrorMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminDeleteServiceError>>\n>;\n\nexport type AdminDeleteServiceErrorMutationError = ErrorType<DmError>;\n\nexport const useAdminDeleteServiceError = <\n TError = ErrorType<DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminDeleteServiceError>>,\n TError,\n { errorId: number },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminDeleteServiceError>>,\n { errorId: number }\n > = (props) => {\n const { errorId } = props ?? {};\n\n return adminDeleteServiceError(errorId, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminDeleteServiceError>>,\n TError,\n { errorId: number },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * This method adds a user to the Data Manager service. The user is authenticated via a keycloak server but will need an initialised account before they can create Datasets or Projects.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Prepares a user account in the Data Manager service\n */\nexport const adminPutUser = (\n userId: string,\n options?: SecondParameter<typeof customInstance>\n) => {\n return customInstance<AdminUserPutResponse>(\n { url: `/admin/user/${userId}`, method: \"put\" },\n options\n );\n};\n\nexport type AdminPutUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminPutUser>>\n>;\n\nexport type AdminPutUserMutationError = ErrorType<void | DmError>;\n\nexport const useAdminPutUser = <\n TError = ErrorType<void | DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminPutUser>>,\n TError,\n { userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminPutUser>>,\n { userId: string }\n > = (props) => {\n const { userId } = props ?? {};\n\n return adminPutUser(userId, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminPutUser>>,\n TError,\n { userId: string },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * Deletes a user account, along with all the user's Datasets\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Deletes a user account\n */\nexport const adminDeleteUser = (\n userId: string,\n options?: SecondParameter<typeof customInstance>\n) => {\n return customInstance<void>(\n { url: `/admin/user/${userId}`, method: \"delete\" },\n options\n );\n};\n\nexport type AdminDeleteUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminDeleteUser>>\n>;\n\nexport type AdminDeleteUserMutationError = ErrorType<DmError>;\n\nexport const useAdminDeleteUser = <\n TError = ErrorType<DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminDeleteUser>>,\n TError,\n { userId: string },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminDeleteUser>>,\n { userId: string }\n > = (props) => {\n const { userId } = props ?? {};\n\n return adminDeleteUser(userId, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminDeleteUser>>,\n TError,\n { userId: string },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * Patches a user record, typically to suspend or re-enable a user account\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Patch a given user\n */\nexport const adminPatchUser = (\n userId: string,\n userPatchBodyBody: UserPatchBodyBody,\n options?: SecondParameter<typeof customInstance>\n) => {\n const formData = new FormData();\n if (userPatchBodyBody.suspend_message !== undefined) {\n formData.append(\"suspend_message\", userPatchBodyBody.suspend_message);\n }\n\n return customInstance<void>(\n {\n url: `/admin/user/${userId}`,\n method: \"patch\",\n headers: { \"Content-Type\": \"multipart/form-data\" },\n data: formData,\n },\n options\n );\n};\n\nexport type AdminPatchUserMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminPatchUser>>\n>;\nexport type AdminPatchUserMutationBody = UserPatchBodyBody;\nexport type AdminPatchUserMutationError = ErrorType<DmError>;\n\nexport const useAdminPatchUser = <\n TError = ErrorType<DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminPatchUser>>,\n TError,\n { userId: string; data: UserPatchBodyBody },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminPatchUser>>,\n { userId: string; data: UserPatchBodyBody }\n > = (props) => {\n const { userId, data } = props ?? {};\n\n return adminPatchUser(userId, data, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminPatchUser>>,\n TError,\n { userId: string; data: UserPatchBodyBody },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * Returns the list of known **Job Manifests** including the time the manifest was last loaded and its load status, a message indicating success or failure.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Get Job Manifests\n */\nexport const adminGetJobManifests = (\n options?: SecondParameter<typeof customInstance>,\n signal?: AbortSignal\n) => {\n return customInstance<AdminJobManifestGetResponse>(\n { url: `/admin/job-manifest`, method: \"get\", signal },\n options\n );\n};\n\nexport const getAdminGetJobManifestsQueryKey = () => [`/admin/job-manifest`];\n\nexport type AdminGetJobManifestsQueryResult = NonNullable<\n Awaited<ReturnType<typeof adminGetJobManifests>>\n>;\nexport type AdminGetJobManifestsQueryError = ErrorType<void | DmError>;\n\nexport const useAdminGetJobManifests = <\n TData = Awaited<ReturnType<typeof adminGetJobManifests>>,\n TError = ErrorType<void | DmError>\n>(options?: {\n query?: UseQueryOptions<\n Awaited<ReturnType<typeof adminGetJobManifests>>,\n TError,\n TData\n >;\n request?: SecondParameter<typeof customInstance>;\n}): UseQueryResult<TData, TError> & { queryKey: QueryKey } => {\n const { query: queryOptions, request: requestOptions } = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getAdminGetJobManifestsQueryKey();\n\n const queryFn: QueryFunction<\n Awaited<ReturnType<typeof adminGetJobManifests>>\n > = ({ signal }) => adminGetJobManifests(requestOptions, signal);\n\n const query = useQuery<\n Awaited<ReturnType<typeof adminGetJobManifests>>,\n TError,\n TData\n >(queryKey, queryFn, queryOptions) as UseQueryResult<TData, TError> & {\n queryKey: QueryKey;\n };\n\n query.queryKey = queryKey;\n\n return query;\n};\n\n/**\n * This endpoint is used to add (or update an existing **Job Manifest**). Manifests are the source of Job definitions. Once added the manifest is inspected and any Jobs it refers to are loaded.\n\nA limited number of manifest origins (URLs) are supported. At the moment we support basic GitHib and GitLab URLs, i.e. those that begin `https://raw.githubusercontent.com/` and `https://gitlab.com/api/v4/projects/`.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Adds a Job Manifest and triggers the download of its Job Definitions\n */\nexport const adminJobManifestPut = (\n jobManifestPutBodyBody: JobManifestPutBodyBody,\n options?: SecondParameter<typeof customInstance>\n) => {\n const formData = new FormData();\n formData.append(\"url\", jobManifestPutBodyBody.url);\n if (jobManifestPutBodyBody.header !== undefined) {\n formData.append(\"header\", jobManifestPutBodyBody.header);\n }\n if (jobManifestPutBodyBody.params !== undefined) {\n formData.append(\"params\", jobManifestPutBodyBody.params);\n }\n\n return customInstance<AdminJobManifestLoadPutResponse>(\n {\n url: `/admin/job-manifest`,\n method: \"put\",\n headers: { \"Content-Type\": \"multipart/form-data\" },\n data: formData,\n },\n options\n );\n};\n\nexport type AdminJobManifestPutMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminJobManifestPut>>\n>;\nexport type AdminJobManifestPutMutationBody = JobManifestPutBodyBody;\nexport type AdminJobManifestPutMutationError = ErrorType<void | DmError>;\n\nexport const useAdminJobManifestPut = <\n TError = ErrorType<void | DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminJobManifestPut>>,\n TError,\n { data: JobManifestPutBodyBody },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminJobManifestPut>>,\n { data: JobManifestPutBodyBody }\n > = (props) => {\n const { data } = props ?? {};\n\n return adminJobManifestPut(data, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminJobManifestPut>>,\n TError,\n { data: JobManifestPutBodyBody },\n TContext\n >(mutationFn, mutationOptions);\n};\n/**\n * This endpoint is used to trigger the Data Manager to re-inspect the internal **Job Manifest** table and download the manifests and reprocess the related job definitions. This is normally done by an administrator when the Manifest table has been modified or if external job definitions are known to have changed in the referenced repositories.\n\nYou will need **admin** rights to use this endpoint\n\n * @summary Trigger a download of Job Definitions using existing Job Manifests\n */\nexport const adminJobManifestLoad = (\n jobManifestLoadPutBodyBody: JobManifestLoadPutBodyBody,\n options?: SecondParameter<typeof customInstance>\n) => {\n const formData = new FormData();\n formData.append(\"purge\", jobManifestLoadPutBodyBody.purge.toString());\n\n return customInstance<AdminJobManifestLoadPutResponse>(\n {\n url: `/admin/job-manifest/load`,\n method: \"put\",\n headers: { \"Content-Type\": \"multipart/form-data\" },\n data: formData,\n },\n options\n );\n};\n\nexport type AdminJobManifestLoadMutationResult = NonNullable<\n Awaited<ReturnType<typeof adminJobManifestLoad>>\n>;\nexport type AdminJobManifestLoadMutationBody = JobManifestLoadPutBodyBody;\nexport type AdminJobManifestLoadMutationError = ErrorType<void | DmError>;\n\nexport const useAdminJobManifestLoad = <\n TError = ErrorType<void | DmError>,\n TContext = unknown\n>(options?: {\n mutation?: UseMutationOptions<\n Awaited<ReturnType<typeof adminJobManifestLoad>>,\n TError,\n { data: JobManifestLoadPutBodyBody },\n TContext\n >;\n request?: SecondParameter<typeof customInstance>;\n}) => {\n const { mutation: mutationOptions, request: requestOptions } = options ?? {};\n\n const mutationFn: MutationFunction<\n Awaited<ReturnType<typeof adminJobManifestLoad>>,\n { data: JobManifestLoadPutBodyBody }\n > = (props) => {\n const { data } = props ?? {};\n\n return adminJobManifestLoad(data, requestOptions);\n };\n\n return useMutation<\n Awaited<ReturnType<typeof adminJobManifestLoad>>,\n TError,\n { data: JobManifestLoadPutBodyBody },\n TContext\n >(mutationFn, mutationOptions);\n};\n"]}
package/admin/admin.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { A as AdminGetServiceErrorsParams, bz as customInstance, aX as ServiceErrorsGetResponse, bA as ErrorType, bv as DmError, aa as UserAccountDetail, W as UserPatchBodyBody, a0 as JobManifestPutBodyBody, bs as AdminJobManifestLoadPutResponse, a1 as JobManifestLoadPutBodyBody } from '../custom-instance-b2f7dca1.js';
1
+ import { A as AdminGetServiceErrorsParams, bB as customInstance, aY as ServiceErrorsGetResponse, bC as ErrorType, bx as DmError, aa as UserAccountDetail, W as UserPatchBodyBody, bu as AdminJobManifestGetResponse, a0 as JobManifestPutBodyBody, bt as AdminJobManifestLoadPutResponse, a1 as JobManifestLoadPutBodyBody } from '../custom-instance-3a73945d.js';
2
2
  import * as react_query from 'react-query';
3
3
  import { UseQueryOptions, QueryKey, UseQueryResult, UseMutationOptions } from 'react-query';
4
4
  import 'axios';
@@ -115,13 +115,30 @@ declare const useAdminPatchUser: <TError = ErrorType<DmError>, TContext = unknow
115
115
  data: UserPatchBodyBody;
116
116
  }, TContext>;
117
117
  /**
118
- * This endpoint is used to add (or update an existing manifest). Manifests are the source of Job definitions. Once added the manifest is inspected and any Jobs it refers to are loaded.
118
+ * Returns the list of known **Job Manifests** including the time the manifest was last loaded and its load status, a message indicating success or failure.
119
+
120
+ You will need **admin** rights to use this endpoint
121
+
122
+ * @summary Get Job Manifests
123
+ */
124
+ declare const adminGetJobManifests: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal | undefined) => Promise<AdminJobManifestGetResponse>;
125
+ declare const getAdminGetJobManifestsQueryKey: () => string[];
126
+ declare type AdminGetJobManifestsQueryResult = NonNullable<Awaited<ReturnType<typeof adminGetJobManifests>>>;
127
+ declare type AdminGetJobManifestsQueryError = ErrorType<void | DmError>;
128
+ declare const useAdminGetJobManifests: <TData = AdminJobManifestGetResponse, TError = ErrorType<void | DmError>>(options?: {
129
+ query?: UseQueryOptions<AdminJobManifestGetResponse, TError, TData, QueryKey> | undefined;
130
+ request?: SecondParameter<typeof customInstance>;
131
+ } | undefined) => UseQueryResult<TData, TError> & {
132
+ queryKey: QueryKey;
133
+ };
134
+ /**
135
+ * This endpoint is used to add (or update an existing **Job Manifest**). Manifests are the source of Job definitions. Once added the manifest is inspected and any Jobs it refers to are loaded.
119
136
 
120
137
  A limited number of manifest origins (URLs) are supported. At the moment we support basic GitHib and GitLab URLs, i.e. those that begin `https://raw.githubusercontent.com/` and `https://gitlab.com/api/v4/projects/`.
121
138
 
122
139
  You will need **admin** rights to use this endpoint
123
140
 
124
- * @summary Adds a manifest and triggers the download of Job Definitions
141
+ * @summary Adds a Job Manifest and triggers the download of its Job Definitions
125
142
  */
126
143
  declare const adminJobManifestPut: (jobManifestPutBodyBody: JobManifestPutBodyBody, options?: SecondParameter<typeof customInstance>) => Promise<AdminJobManifestLoadPutResponse>;
127
144
  declare type AdminJobManifestPutMutationResult = NonNullable<Awaited<ReturnType<typeof adminJobManifestPut>>>;
@@ -136,11 +153,11 @@ declare const useAdminJobManifestPut: <TError = ErrorType<void | DmError>, TCont
136
153
  data: JobManifestPutBodyBody;
137
154
  }, TContext>;
138
155
  /**
139
- * This endpoint is used to trigger the Data Manager to re-inspect the internal Job **Manifest** table and download the manifests and reprocess the related job definitions. This is normally done by an administrator when the Manifest table has been modified or if external job definitions are known to have changed in the referenced repositories.
156
+ * This endpoint is used to trigger the Data Manager to re-inspect the internal **Job Manifest** table and download the manifests and reprocess the related job definitions. This is normally done by an administrator when the Manifest table has been modified or if external job definitions are known to have changed in the referenced repositories.
140
157
 
141
158
  You will need **admin** rights to use this endpoint
142
159
 
143
- * @summary Trigger a download of known Job Definitions using the Manifest table
160
+ * @summary Trigger a download of Job Definitions using existing Job Manifests
144
161
  */
145
162
  declare const adminJobManifestLoad: (jobManifestLoadPutBodyBody: JobManifestLoadPutBodyBody, options?: SecondParameter<typeof customInstance>) => Promise<AdminJobManifestLoadPutResponse>;
146
163
  declare type AdminJobManifestLoadMutationResult = NonNullable<Awaited<ReturnType<typeof adminJobManifestLoad>>>;
@@ -155,4 +172,4 @@ declare const useAdminJobManifestLoad: <TError = ErrorType<void | DmError>, TCon
155
172
  data: JobManifestLoadPutBodyBody;
156
173
  }, TContext>;
157
174
 
158
- export { AdminDeleteServiceErrorMutationError, AdminDeleteServiceErrorMutationResult, AdminDeleteUserMutationError, AdminDeleteUserMutationResult, AdminGetServiceErrorsQueryError, AdminGetServiceErrorsQueryResult, AdminJobManifestLoadMutationBody, AdminJobManifestLoadMutationError, AdminJobManifestLoadMutationResult, AdminJobManifestPutMutationBody, AdminJobManifestPutMutationError, AdminJobManifestPutMutationResult, AdminPatchServiceErrorMutationError, AdminPatchServiceErrorMutationResult, AdminPatchUserMutationBody, AdminPatchUserMutationError, AdminPatchUserMutationResult, AdminPutUserMutationError, AdminPutUserMutationResult, adminDeleteServiceError, adminDeleteUser, adminGetServiceErrors, adminJobManifestLoad, adminJobManifestPut, adminPatchServiceError, adminPatchUser, adminPutUser, getAdminGetServiceErrorsQueryKey, useAdminDeleteServiceError, useAdminDeleteUser, useAdminGetServiceErrors, useAdminJobManifestLoad, useAdminJobManifestPut, useAdminPatchServiceError, useAdminPatchUser, useAdminPutUser };
175
+ export { AdminDeleteServiceErrorMutationError, AdminDeleteServiceErrorMutationResult, AdminDeleteUserMutationError, AdminDeleteUserMutationResult, AdminGetJobManifestsQueryError, AdminGetJobManifestsQueryResult, AdminGetServiceErrorsQueryError, AdminGetServiceErrorsQueryResult, AdminJobManifestLoadMutationBody, AdminJobManifestLoadMutationError, AdminJobManifestLoadMutationResult, AdminJobManifestPutMutationBody, AdminJobManifestPutMutationError, AdminJobManifestPutMutationResult, AdminPatchServiceErrorMutationError, AdminPatchServiceErrorMutationResult, AdminPatchUserMutationBody, AdminPatchUserMutationError, AdminPatchUserMutationResult, AdminPutUserMutationError, AdminPutUserMutationResult, adminDeleteServiceError, adminDeleteUser, adminGetJobManifests, adminGetServiceErrors, adminJobManifestLoad, adminJobManifestPut, adminPatchServiceError, adminPatchUser, adminPutUser, getAdminGetJobManifestsQueryKey, getAdminGetServiceErrorsQueryKey, useAdminDeleteServiceError, useAdminDeleteUser, useAdminGetJobManifests, useAdminGetServiceErrors, useAdminJobManifestLoad, useAdminJobManifestPut, useAdminPatchServiceError, useAdminPatchUser, useAdminPutUser };