@squonk/account-server-client 4.2.0-alpha.8 → 4.2.0-beta.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.
@@ -1 +1 @@
1
- {"version":3,"sources":["/home/runner/work/squonk2-account-server-js-client/squonk2-account-server-js-client/dist/event-stream/event-stream.cjs","../../src/event-stream/event-stream.ts"],"names":[],"mappings":"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","file":"/home/runner/work/squonk2-account-server-js-client/squonk2-account-server-js-client/dist/event-stream/event-stream.cjs","sourcesContent":[null,"// @ts-nocheck\n/**\n * Generated by orval v7.4.1 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.2\n */\nimport {\n useMutation,\n useQuery,\n useSuspenseQuery\n} from '@tanstack/react-query'\nimport type {\n DataTag,\n DefinedInitialDataOptions,\n DefinedUseQueryResult,\n MutationFunction,\n QueryFunction,\n QueryKey,\n UndefinedInitialDataOptions,\n UseMutationOptions,\n UseMutationResult,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult\n} from '@tanstack/react-query'\nimport type {\n AsError,\n EventStreamGetPostResponse\n} from '../account-server-api.schemas'\nimport { customInstance } from '.././custom-instance';\nimport type { ErrorType } from '.././custom-instance';\n\n\ntype SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];\n\n\n/**\n * Gets your EventStream ID and read token, if you have created one.\n\n * @summary Gets the details of your EventStream\n */\nexport const getEventStream = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<EventStreamGetPostResponse>(\n {url: `/event-stream`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetEventStreamQueryKey = () => {\n return [\"account-server-api\", `/event-stream`] as const;\n }\n\n \nexport const getGetEventStreamQueryOptions = <TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetEventStreamQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getEventStream>>> = ({ signal }) => getEventStream(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData> & { queryKey: DataTag<QueryKey, TData, TError> }\n}\n\nexport type GetEventStreamQueryResult = NonNullable<Awaited<ReturnType<typeof getEventStream>>>\nexport type GetEventStreamQueryError = ErrorType<void | AsError>\n\n\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options: { query:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>> & Pick<\n DefinedInitialDataOptions<\n Awaited<ReturnType<typeof getEventStream>>,\n TError,\n TData\n > , 'initialData'\n >, request?: SecondParameter<typeof customInstance>}\n\n ): DefinedUseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>> & Pick<\n UndefinedInitialDataOptions<\n Awaited<ReturnType<typeof getEventStream>>,\n TError,\n TData\n > , 'initialData'\n >, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\n/**\n * @summary Gets the details of your EventStream\n */\n\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> } {\n\n const queryOptions = getGetEventStreamQueryOptions(options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\nexport const getGetEventStreamSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetEventStreamQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getEventStream>>> = ({ signal }) => getEventStream(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData> & { queryKey: DataTag<QueryKey, TData, TError> }\n}\n\nexport type GetEventStreamSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getEventStream>>>\nexport type GetEventStreamSuspenseQueryError = ErrorType<void | AsError>\n\n\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options: { query:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\n/**\n * @summary Gets the details of your EventStream\n */\n\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> } {\n\n const queryOptions = getGetEventStreamSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Creates a new event stream for the authenticated user.\n\nA user is only permitted one event stream.\n\n * @summary Create a new Server-Sent Events EventStream\n */\nexport const createEventStream = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<EventStreamGetPostResponse>(\n {url: `/event-stream`, method: 'POST', signal\n },\n options);\n }\n \n\n\nexport const getCreateEventStreamMutationOptions = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\nconst mutationKey = ['createEventStream'];\nconst {mutation: mutationOptions, request: requestOptions} = options ?\n options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?\n options\n : {...options, mutation: {...options.mutation, mutationKey}}\n : {mutation: { mutationKey, }, request: undefined};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof createEventStream>>, void> = () => {\n \n\n return createEventStream(requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions } as UseMutationOptions<TData, TError,void, TContext>}\n\n export type CreateEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof createEventStream>>>\n \n export type CreateEventStreamMutationError = ErrorType<AsError | void>\n\n /**\n * @summary Create a new Server-Sent Events EventStream\n */\nexport const useCreateEventStream = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationResult<\n TData,\n TError,\n void,\n TContext\n > => {\n\n const mutationOptions = getCreateEventStreamMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Deletes an Event Stream.\n\nYou must be the user who created the event stream.\n\n * @summary Deletes an existing EventStream (that you created)\n */\nexport const deleteEventStream = (\n eventStreamId: number,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/event-stream/${eventStreamId}`, method: 'DELETE'\n },\n options);\n }\n \n\n\nexport const getDeleteEventStreamMutationOptions = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\nconst mutationKey = ['deleteEventStream'];\nconst {mutation: mutationOptions, request: requestOptions} = options ?\n options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?\n options\n : {...options, mutation: {...options.mutation, mutationKey}}\n : {mutation: { mutationKey, }, request: undefined};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof deleteEventStream>>, {eventStreamId: number}> = (props) => {\n const {eventStreamId} = props ?? {};\n\n return deleteEventStream(eventStreamId,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions } as UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>}\n\n export type DeleteEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof deleteEventStream>>>\n \n export type DeleteEventStreamMutationError = ErrorType<void | AsError>\n\n /**\n * @summary Deletes an existing EventStream (that you created)\n */\nexport const useDeleteEventStream = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationResult<\n TData,\n TError,\n {eventStreamId: number},\n TContext\n > => {\n\n const mutationOptions = getDeleteEventStreamMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n "]}
1
+ {"version":3,"sources":["/home/runner/work/squonk2-account-server-js-client/squonk2-account-server-js-client/dist/event-stream/event-stream.cjs","../../src/event-stream/event-stream.ts"],"names":[],"mappings":"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","file":"/home/runner/work/squonk2-account-server-js-client/squonk2-account-server-js-client/dist/event-stream/event-stream.cjs","sourcesContent":[null,"// @ts-nocheck\n/**\n * Generated by orval v7.4.1 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.2\n */\nimport {\n useMutation,\n useQuery,\n useSuspenseQuery\n} from '@tanstack/react-query'\nimport type {\n DataTag,\n DefinedInitialDataOptions,\n DefinedUseQueryResult,\n MutationFunction,\n QueryFunction,\n QueryKey,\n UndefinedInitialDataOptions,\n UseMutationOptions,\n UseMutationResult,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult\n} from '@tanstack/react-query'\nimport type {\n AsError,\n EventStreamGetPostResponse\n} from '../account-server-api.schemas'\nimport { customInstance } from '.././custom-instance';\nimport type { ErrorType } from '.././custom-instance';\n\n\ntype SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];\n\n\n/**\n * Gets the details of your event stream, if you have created one. The response includes the event stream ID and the **location** where events can be accessed.\n\n * @summary Gets the details of your event stream\n */\nexport const getEventStream = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<EventStreamGetPostResponse>(\n {url: `/event-stream`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetEventStreamQueryKey = () => {\n return [\"account-server-api\", `/event-stream`] as const;\n }\n\n \nexport const getGetEventStreamQueryOptions = <TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetEventStreamQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getEventStream>>> = ({ signal }) => getEventStream(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData> & { queryKey: DataTag<QueryKey, TData, TError> }\n}\n\nexport type GetEventStreamQueryResult = NonNullable<Awaited<ReturnType<typeof getEventStream>>>\nexport type GetEventStreamQueryError = ErrorType<void | AsError>\n\n\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options: { query:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>> & Pick<\n DefinedInitialDataOptions<\n Awaited<ReturnType<typeof getEventStream>>,\n TError,\n TData\n > , 'initialData'\n >, request?: SecondParameter<typeof customInstance>}\n\n ): DefinedUseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>> & Pick<\n UndefinedInitialDataOptions<\n Awaited<ReturnType<typeof getEventStream>>,\n TError,\n TData\n > , 'initialData'\n >, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\n/**\n * @summary Gets the details of your event stream\n */\n\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> } {\n\n const queryOptions = getGetEventStreamQueryOptions(options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\nexport const getGetEventStreamSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetEventStreamQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getEventStream>>> = ({ signal }) => getEventStream(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData> & { queryKey: DataTag<QueryKey, TData, TError> }\n}\n\nexport type GetEventStreamSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getEventStream>>>\nexport type GetEventStreamSuspenseQueryError = ErrorType<void | AsError>\n\n\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options: { query:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\n/**\n * @summary Gets the details of your event stream\n */\n\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> } {\n\n const queryOptions = getGetEventStreamSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Creates a new event stream for the authenticated user. The event Stream delivers near-real-time events to the user where the implementation is dependent on the Event Stream Service that has been installed. Our **Python FastAPI WebSocket** service is one such service.\n\nThe response will include the event stream ID and the **location** where events can be accessed.\n\nThe event streaming service is an optional component of the Account Server. If a service is not installed you will receive a corresponding **404** response.\n\nA user is only permitted one event stream.\n\n * @summary Create a new event stream\n */\nexport const createEventStream = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<EventStreamGetPostResponse>(\n {url: `/event-stream`, method: 'POST', signal\n },\n options);\n }\n \n\n\nexport const getCreateEventStreamMutationOptions = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\nconst mutationKey = ['createEventStream'];\nconst {mutation: mutationOptions, request: requestOptions} = options ?\n options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?\n options\n : {...options, mutation: {...options.mutation, mutationKey}}\n : {mutation: { mutationKey, }, request: undefined};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof createEventStream>>, void> = () => {\n \n\n return createEventStream(requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions } as UseMutationOptions<TData, TError,void, TContext>}\n\n export type CreateEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof createEventStream>>>\n \n export type CreateEventStreamMutationError = ErrorType<AsError | void>\n\n /**\n * @summary Create a new event stream\n */\nexport const useCreateEventStream = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationResult<\n TData,\n TError,\n void,\n TContext\n > => {\n\n const mutationOptions = getCreateEventStreamMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * You must be the user who created the event stream.\n\n * @summary Deletes an existing event stream (that you created)\n */\nexport const deleteEventStream = (\n eventStreamId: number,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/event-stream/${eventStreamId}`, method: 'DELETE'\n },\n options);\n }\n \n\n\nexport const getDeleteEventStreamMutationOptions = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\nconst mutationKey = ['deleteEventStream'];\nconst {mutation: mutationOptions, request: requestOptions} = options ?\n options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?\n options\n : {...options, mutation: {...options.mutation, mutationKey}}\n : {mutation: { mutationKey, }, request: undefined};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof deleteEventStream>>, {eventStreamId: number}> = (props) => {\n const {eventStreamId} = props ?? {};\n\n return deleteEventStream(eventStreamId,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions } as UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>}\n\n export type DeleteEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof deleteEventStream>>>\n \n export type DeleteEventStreamMutationError = ErrorType<void | AsError>\n\n /**\n * @summary Deletes an existing event stream (that you created)\n */\nexport const useDeleteEventStream = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationResult<\n TData,\n TError,\n {eventStreamId: number},\n TContext\n > => {\n\n const mutationOptions = getDeleteEventStreamMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n "]}
@@ -4,9 +4,9 @@ import 'axios';
4
4
 
5
5
  type SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];
6
6
  /**
7
- * Gets your EventStream ID and read token, if you have created one.
7
+ * Gets the details of your event stream, if you have created one. The response includes the event stream ID and the **location** where events can be accessed.
8
8
 
9
- * @summary Gets the details of your EventStream
9
+ * @summary Gets the details of your event stream
10
10
  */
11
11
  declare const getEventStream: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<EventStreamGetPostResponse>;
12
12
  declare const getGetEventStreamQueryKey: () => readonly ["account-server-api", "/event-stream"];
@@ -63,11 +63,15 @@ declare function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof get
63
63
  queryKey: DataTag<QueryKey, TData, TError>;
64
64
  };
65
65
  /**
66
- * Creates a new event stream for the authenticated user.
66
+ * Creates a new event stream for the authenticated user. The event Stream delivers near-real-time events to the user where the implementation is dependent on the Event Stream Service that has been installed. Our **Python FastAPI WebSocket** service is one such service.
67
+
68
+ The response will include the event stream ID and the **location** where events can be accessed.
69
+
70
+ The event streaming service is an optional component of the Account Server. If a service is not installed you will receive a corresponding **404** response.
67
71
 
68
72
  A user is only permitted one event stream.
69
73
 
70
- * @summary Create a new Server-Sent Events EventStream
74
+ * @summary Create a new event stream
71
75
  */
72
76
  declare const createEventStream: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<EventStreamGetPostResponse>;
73
77
  declare const getCreateEventStreamMutationOptions: <TData = EventStreamGetPostResponse, TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
@@ -77,18 +81,16 @@ declare const getCreateEventStreamMutationOptions: <TData = EventStreamGetPostRe
77
81
  type CreateEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof createEventStream>>>;
78
82
  type CreateEventStreamMutationError = ErrorType<AsError | void>;
79
83
  /**
80
- * @summary Create a new Server-Sent Events EventStream
84
+ * @summary Create a new event stream
81
85
  */
82
86
  declare const useCreateEventStream: <TData = EventStreamGetPostResponse, TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
83
87
  mutation?: UseMutationOptions<TData, TError, void, TContext>;
84
88
  request?: SecondParameter<typeof customInstance>;
85
89
  }) => UseMutationResult<TData, TError, void, TContext>;
86
90
  /**
87
- * Deletes an Event Stream.
88
-
89
- You must be the user who created the event stream.
91
+ * You must be the user who created the event stream.
90
92
 
91
- * @summary Deletes an existing EventStream (that you created)
93
+ * @summary Deletes an existing event stream (that you created)
92
94
  */
93
95
  declare const deleteEventStream: (eventStreamId: number, options?: SecondParameter<typeof customInstance>) => Promise<void>;
94
96
  declare const getDeleteEventStreamMutationOptions: <TData = void, TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
@@ -102,7 +104,7 @@ declare const getDeleteEventStreamMutationOptions: <TData = void, TError = Error
102
104
  type DeleteEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof deleteEventStream>>>;
103
105
  type DeleteEventStreamMutationError = ErrorType<void | AsError>;
104
106
  /**
105
- * @summary Deletes an existing EventStream (that you created)
107
+ * @summary Deletes an existing event stream (that you created)
106
108
  */
107
109
  declare const useDeleteEventStream: <TData = void, TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
108
110
  mutation?: UseMutationOptions<TData, TError, {
@@ -4,9 +4,9 @@ import 'axios';
4
4
 
5
5
  type SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];
6
6
  /**
7
- * Gets your EventStream ID and read token, if you have created one.
7
+ * Gets the details of your event stream, if you have created one. The response includes the event stream ID and the **location** where events can be accessed.
8
8
 
9
- * @summary Gets the details of your EventStream
9
+ * @summary Gets the details of your event stream
10
10
  */
11
11
  declare const getEventStream: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<EventStreamGetPostResponse>;
12
12
  declare const getGetEventStreamQueryKey: () => readonly ["account-server-api", "/event-stream"];
@@ -63,11 +63,15 @@ declare function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof get
63
63
  queryKey: DataTag<QueryKey, TData, TError>;
64
64
  };
65
65
  /**
66
- * Creates a new event stream for the authenticated user.
66
+ * Creates a new event stream for the authenticated user. The event Stream delivers near-real-time events to the user where the implementation is dependent on the Event Stream Service that has been installed. Our **Python FastAPI WebSocket** service is one such service.
67
+
68
+ The response will include the event stream ID and the **location** where events can be accessed.
69
+
70
+ The event streaming service is an optional component of the Account Server. If a service is not installed you will receive a corresponding **404** response.
67
71
 
68
72
  A user is only permitted one event stream.
69
73
 
70
- * @summary Create a new Server-Sent Events EventStream
74
+ * @summary Create a new event stream
71
75
  */
72
76
  declare const createEventStream: (options?: SecondParameter<typeof customInstance>, signal?: AbortSignal) => Promise<EventStreamGetPostResponse>;
73
77
  declare const getCreateEventStreamMutationOptions: <TData = EventStreamGetPostResponse, TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
@@ -77,18 +81,16 @@ declare const getCreateEventStreamMutationOptions: <TData = EventStreamGetPostRe
77
81
  type CreateEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof createEventStream>>>;
78
82
  type CreateEventStreamMutationError = ErrorType<AsError | void>;
79
83
  /**
80
- * @summary Create a new Server-Sent Events EventStream
84
+ * @summary Create a new event stream
81
85
  */
82
86
  declare const useCreateEventStream: <TData = EventStreamGetPostResponse, TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
83
87
  mutation?: UseMutationOptions<TData, TError, void, TContext>;
84
88
  request?: SecondParameter<typeof customInstance>;
85
89
  }) => UseMutationResult<TData, TError, void, TContext>;
86
90
  /**
87
- * Deletes an Event Stream.
88
-
89
- You must be the user who created the event stream.
91
+ * You must be the user who created the event stream.
90
92
 
91
- * @summary Deletes an existing EventStream (that you created)
93
+ * @summary Deletes an existing event stream (that you created)
92
94
  */
93
95
  declare const deleteEventStream: (eventStreamId: number, options?: SecondParameter<typeof customInstance>) => Promise<void>;
94
96
  declare const getDeleteEventStreamMutationOptions: <TData = void, TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
@@ -102,7 +104,7 @@ declare const getDeleteEventStreamMutationOptions: <TData = void, TError = Error
102
104
  type DeleteEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof deleteEventStream>>>;
103
105
  type DeleteEventStreamMutationError = ErrorType<void | AsError>;
104
106
  /**
105
- * @summary Deletes an existing EventStream (that you created)
107
+ * @summary Deletes an existing event stream (that you created)
106
108
  */
107
109
  declare const useDeleteEventStream: <TData = void, TError = ErrorType<void | AsError>, TContext = unknown>(options?: {
108
110
  mutation?: UseMutationOptions<TData, TError, {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/event-stream/event-stream.ts"],"sourcesContent":["// @ts-nocheck\n/**\n * Generated by orval v7.4.1 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.2\n */\nimport {\n useMutation,\n useQuery,\n useSuspenseQuery\n} from '@tanstack/react-query'\nimport type {\n DataTag,\n DefinedInitialDataOptions,\n DefinedUseQueryResult,\n MutationFunction,\n QueryFunction,\n QueryKey,\n UndefinedInitialDataOptions,\n UseMutationOptions,\n UseMutationResult,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult\n} from '@tanstack/react-query'\nimport type {\n AsError,\n EventStreamGetPostResponse\n} from '../account-server-api.schemas'\nimport { customInstance } from '.././custom-instance';\nimport type { ErrorType } from '.././custom-instance';\n\n\ntype SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];\n\n\n/**\n * Gets your EventStream ID and read token, if you have created one.\n\n * @summary Gets the details of your EventStream\n */\nexport const getEventStream = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<EventStreamGetPostResponse>(\n {url: `/event-stream`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetEventStreamQueryKey = () => {\n return [\"account-server-api\", `/event-stream`] as const;\n }\n\n \nexport const getGetEventStreamQueryOptions = <TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetEventStreamQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getEventStream>>> = ({ signal }) => getEventStream(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData> & { queryKey: DataTag<QueryKey, TData, TError> }\n}\n\nexport type GetEventStreamQueryResult = NonNullable<Awaited<ReturnType<typeof getEventStream>>>\nexport type GetEventStreamQueryError = ErrorType<void | AsError>\n\n\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options: { query:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>> & Pick<\n DefinedInitialDataOptions<\n Awaited<ReturnType<typeof getEventStream>>,\n TError,\n TData\n > , 'initialData'\n >, request?: SecondParameter<typeof customInstance>}\n\n ): DefinedUseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>> & Pick<\n UndefinedInitialDataOptions<\n Awaited<ReturnType<typeof getEventStream>>,\n TError,\n TData\n > , 'initialData'\n >, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\n/**\n * @summary Gets the details of your EventStream\n */\n\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> } {\n\n const queryOptions = getGetEventStreamQueryOptions(options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\nexport const getGetEventStreamSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetEventStreamQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getEventStream>>> = ({ signal }) => getEventStream(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData> & { queryKey: DataTag<QueryKey, TData, TError> }\n}\n\nexport type GetEventStreamSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getEventStream>>>\nexport type GetEventStreamSuspenseQueryError = ErrorType<void | AsError>\n\n\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options: { query:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\n/**\n * @summary Gets the details of your EventStream\n */\n\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> } {\n\n const queryOptions = getGetEventStreamSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Creates a new event stream for the authenticated user.\n\nA user is only permitted one event stream.\n\n * @summary Create a new Server-Sent Events EventStream\n */\nexport const createEventStream = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<EventStreamGetPostResponse>(\n {url: `/event-stream`, method: 'POST', signal\n },\n options);\n }\n \n\n\nexport const getCreateEventStreamMutationOptions = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\nconst mutationKey = ['createEventStream'];\nconst {mutation: mutationOptions, request: requestOptions} = options ?\n options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?\n options\n : {...options, mutation: {...options.mutation, mutationKey}}\n : {mutation: { mutationKey, }, request: undefined};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof createEventStream>>, void> = () => {\n \n\n return createEventStream(requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions } as UseMutationOptions<TData, TError,void, TContext>}\n\n export type CreateEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof createEventStream>>>\n \n export type CreateEventStreamMutationError = ErrorType<AsError | void>\n\n /**\n * @summary Create a new Server-Sent Events EventStream\n */\nexport const useCreateEventStream = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationResult<\n TData,\n TError,\n void,\n TContext\n > => {\n\n const mutationOptions = getCreateEventStreamMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * Deletes an Event Stream.\n\nYou must be the user who created the event stream.\n\n * @summary Deletes an existing EventStream (that you created)\n */\nexport const deleteEventStream = (\n eventStreamId: number,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/event-stream/${eventStreamId}`, method: 'DELETE'\n },\n options);\n }\n \n\n\nexport const getDeleteEventStreamMutationOptions = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\nconst mutationKey = ['deleteEventStream'];\nconst {mutation: mutationOptions, request: requestOptions} = options ?\n options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?\n options\n : {...options, mutation: {...options.mutation, mutationKey}}\n : {mutation: { mutationKey, }, request: undefined};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof deleteEventStream>>, {eventStreamId: number}> = (props) => {\n const {eventStreamId} = props ?? {};\n\n return deleteEventStream(eventStreamId,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions } as UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>}\n\n export type DeleteEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof deleteEventStream>>>\n \n export type DeleteEventStreamMutationError = ErrorType<void | AsError>\n\n /**\n * @summary Deletes an existing EventStream (that you created)\n */\nexport const useDeleteEventStream = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationResult<\n TData,\n TError,\n {eventStreamId: number},\n TContext\n > => {\n\n const mutationOptions = getDeleteEventStreamMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n "],"mappings":"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","names":[]}
1
+ {"version":3,"sources":["../../src/event-stream/event-stream.ts"],"sourcesContent":["// @ts-nocheck\n/**\n * Generated by orval v7.4.1 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.2\n */\nimport {\n useMutation,\n useQuery,\n useSuspenseQuery\n} from '@tanstack/react-query'\nimport type {\n DataTag,\n DefinedInitialDataOptions,\n DefinedUseQueryResult,\n MutationFunction,\n QueryFunction,\n QueryKey,\n UndefinedInitialDataOptions,\n UseMutationOptions,\n UseMutationResult,\n UseQueryOptions,\n UseQueryResult,\n UseSuspenseQueryOptions,\n UseSuspenseQueryResult\n} from '@tanstack/react-query'\nimport type {\n AsError,\n EventStreamGetPostResponse\n} from '../account-server-api.schemas'\nimport { customInstance } from '.././custom-instance';\nimport type { ErrorType } from '.././custom-instance';\n\n\ntype SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];\n\n\n/**\n * Gets the details of your event stream, if you have created one. The response includes the event stream ID and the **location** where events can be accessed.\n\n * @summary Gets the details of your event stream\n */\nexport const getEventStream = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<EventStreamGetPostResponse>(\n {url: `/event-stream`, method: 'GET', signal\n },\n options);\n }\n \n\nexport const getGetEventStreamQueryKey = () => {\n return [\"account-server-api\", `/event-stream`] as const;\n }\n\n \nexport const getGetEventStreamQueryOptions = <TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetEventStreamQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getEventStream>>> = ({ signal }) => getEventStream(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData> & { queryKey: DataTag<QueryKey, TData, TError> }\n}\n\nexport type GetEventStreamQueryResult = NonNullable<Awaited<ReturnType<typeof getEventStream>>>\nexport type GetEventStreamQueryError = ErrorType<void | AsError>\n\n\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options: { query:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>> & Pick<\n DefinedInitialDataOptions<\n Awaited<ReturnType<typeof getEventStream>>,\n TError,\n TData\n > , 'initialData'\n >, request?: SecondParameter<typeof customInstance>}\n\n ): DefinedUseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>> & Pick<\n UndefinedInitialDataOptions<\n Awaited<ReturnType<typeof getEventStream>>,\n TError,\n TData\n > , 'initialData'\n >, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\n/**\n * @summary Gets the details of your event stream\n */\n\nexport function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> } {\n\n const queryOptions = getGetEventStreamQueryOptions(options)\n\n const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\nexport const getGetEventStreamSuspenseQueryOptions = <TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>( options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n) => {\n\nconst {query: queryOptions, request: requestOptions} = options ?? {};\n\n const queryKey = queryOptions?.queryKey ?? getGetEventStreamQueryKey();\n\n \n\n const queryFn: QueryFunction<Awaited<ReturnType<typeof getEventStream>>> = ({ signal }) => getEventStream(requestOptions, signal);\n\n \n\n \n\n return { queryKey, queryFn, ...queryOptions} as UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData> & { queryKey: DataTag<QueryKey, TData, TError> }\n}\n\nexport type GetEventStreamSuspenseQueryResult = NonNullable<Awaited<ReturnType<typeof getEventStream>>>\nexport type GetEventStreamSuspenseQueryError = ErrorType<void | AsError>\n\n\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options: { query:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }\n/**\n * @summary Gets the details of your event stream\n */\n\nexport function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(\n options?: { query?:Partial<UseSuspenseQueryOptions<Awaited<ReturnType<typeof getEventStream>>, TError, TData>>, request?: SecondParameter<typeof customInstance>}\n\n ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> } {\n\n const queryOptions = getGetEventStreamSuspenseQueryOptions(options)\n\n const query = useSuspenseQuery(queryOptions) as UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> };\n\n query.queryKey = queryOptions.queryKey ;\n\n return query;\n}\n\n\n\n/**\n * Creates a new event stream for the authenticated user. The event Stream delivers near-real-time events to the user where the implementation is dependent on the Event Stream Service that has been installed. Our **Python FastAPI WebSocket** service is one such service.\n\nThe response will include the event stream ID and the **location** where events can be accessed.\n\nThe event streaming service is an optional component of the Account Server. If a service is not installed you will receive a corresponding **404** response.\n\nA user is only permitted one event stream.\n\n * @summary Create a new event stream\n */\nexport const createEventStream = (\n \n options?: SecondParameter<typeof customInstance>,signal?: AbortSignal\n) => {\n \n \n return customInstance<EventStreamGetPostResponse>(\n {url: `/event-stream`, method: 'POST', signal\n },\n options);\n }\n \n\n\nexport const getCreateEventStreamMutationOptions = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\nconst mutationKey = ['createEventStream'];\nconst {mutation: mutationOptions, request: requestOptions} = options ?\n options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?\n options\n : {...options, mutation: {...options.mutation, mutationKey}}\n : {mutation: { mutationKey, }, request: undefined};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof createEventStream>>, void> = () => {\n \n\n return createEventStream(requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions } as UseMutationOptions<TData, TError,void, TContext>}\n\n export type CreateEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof createEventStream>>>\n \n export type CreateEventStreamMutationError = ErrorType<AsError | void>\n\n /**\n * @summary Create a new event stream\n */\nexport const useCreateEventStream = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationResult<\n TData,\n TError,\n void,\n TContext\n > => {\n\n const mutationOptions = getCreateEventStreamMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n /**\n * You must be the user who created the event stream.\n\n * @summary Deletes an existing event stream (that you created)\n */\nexport const deleteEventStream = (\n eventStreamId: number,\n options?: SecondParameter<typeof customInstance>,) => {\n \n \n return customInstance<void>(\n {url: `/event-stream/${eventStreamId}`, method: 'DELETE'\n },\n options);\n }\n \n\n\nexport const getDeleteEventStreamMutationOptions = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}\n) => {\nconst mutationKey = ['deleteEventStream'];\nconst {mutation: mutationOptions, request: requestOptions} = options ?\n options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?\n options\n : {...options, mutation: {...options.mutation, mutationKey}}\n : {mutation: { mutationKey, }, request: undefined};\n\n \n\n\n const mutationFn: MutationFunction<Awaited<ReturnType<typeof deleteEventStream>>, {eventStreamId: number}> = (props) => {\n const {eventStreamId} = props ?? {};\n\n return deleteEventStream(eventStreamId,requestOptions)\n }\n\n \n\n\n return { mutationFn, ...mutationOptions } as UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>}\n\n export type DeleteEventStreamMutationResult = NonNullable<Awaited<ReturnType<typeof deleteEventStream>>>\n \n export type DeleteEventStreamMutationError = ErrorType<void | AsError>\n\n /**\n * @summary Deletes an existing event stream (that you created)\n */\nexport const useDeleteEventStream = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,\n TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}\n): UseMutationResult<\n TData,\n TError,\n {eventStreamId: number},\n TContext\n > => {\n\n const mutationOptions = getDeleteEventStreamMutationOptions(options);\n\n return useMutation(mutationOptions);\n }\n "],"mappings":"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","names":[]}
package/index.cjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["/home/runner/work/squonk2-account-server-js-client/squonk2-account-server-js-client/dist/index.cjs","../src/account-server-api.schemas.ts"],"names":[],"mappings":"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","file":"/home/runner/work/squonk2-account-server-js-client/squonk2-account-server-js-client/dist/index.cjs","sourcesContent":[null,"// @ts-nocheck\n/**\n * Generated by orval v7.4.1 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.2\n */\nexport type DetachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type AttachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type GetUnitsParams = {\n/**\n * An object name\n */\nname?: QNameParameter;\n};\n\nexport type GetOrganisationsParams = {\n/**\n * An object name\n */\nname?: QNameParameter;\n};\n\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QUntilParameter = string;\n\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QFromParameter = string;\n\nexport type GetProductChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetOrganisationChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\n/**\n * A User Identity\n */\nexport type QUserIdParameter = string;\n\n/**\n * A Product Identity\n */\nexport type QProductIdParameter = string;\n\n/**\n * A Unit Identity\n */\nexport type QUnitIdParameter = string;\n\n/**\n * An object name\n */\nexport type QNameParameter = string;\n\n/**\n * A Merchant Identity\n */\nexport type QMIdParameter = number;\n\n/**\n * An Organisation Identity\n */\nexport type QOrgIdParameter = string;\n\nexport type GetAssetParams = {\n/**\n * A User Identity\n */\nuser_id?: QUserIdParameter;\n/**\n * A Product Identity\n */\nproduct_id?: QProductIdParameter;\n/**\n * A Unit Identity\n */\nunit_id?: QUnitIdParameter;\n/**\n * An Organisation Identity\n */\norg_id?: QOrgIdParameter;\n};\n\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\nexport type QPbpParameter = number;\n\nexport type GetUnitChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type ProductPatchBodyBody = {\n /**\n * The name you want to give the Product\n * @maxLength 80\n */\n name?: string;\n /**\n * The Product's built-in coin allowance. Product allowances cannot be reduced\n * @minimum 1\n */\n allowance?: number;\n /**\n * The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. The existing product limit cannot be reduced\n * @minimum 1\n */\n limit?: number;\n};\n\n/**\n * The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products\n */\nexport type UnitProductPostBodyBodyFlavour = typeof UnitProductPostBodyBodyFlavour[keyof typeof UnitProductPostBodyBodyFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\n/**\n * The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products\n */\nexport type UnitProductPostBodyBodyType = typeof UnitProductPostBodyBodyType[keyof typeof UnitProductPostBodyBodyType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport type UnitProductPostBodyBody = {\n /**\n * The name you want to give the Product\n * @maxLength 80\n */\n name: string;\n /** The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products */\n type: UnitProductPostBodyBodyType;\n /** The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products */\n flavour?: UnitProductPostBodyBodyFlavour;\n /**\n * The Product's coin allowance. You must provide this for Storage products but you must not provide a value for Project Tier Products\n * @minimum 1\n */\n allowance?: number;\n /**\n * The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. You can provide this for Storage products but you must not provide a value for Project Tier Products\n * @minimum 1\n */\n limit?: number;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value\n */\nexport type UnitPatchBodyBodyDefaultProductPrivacy = typeof UnitPatchBodyBodyDefaultProductPrivacy[keyof typeof UnitPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type UnitPatchBodyBody = {\n /** The new name for the Unit */\n name?: string;\n /** The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: UnitPatchBodyBodyDefaultProductPrivacy;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units\n */\nexport type OrganisationPatchBodyBodyDefaultProductPrivacy = typeof OrganisationPatchBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPatchBodyBody = {\n /** The new name for the Organisational */\n name?: string;\n /** The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units */\n default_product_privacy?: OrganisationPatchBodyBodyDefaultProductPrivacy;\n};\n\n/**\n * The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value\n */\nexport type OrganisationUnitPostBodyBodyDefaultProductPrivacy = typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationUnitPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationUnitPostBodyBody = {\n /**\n * The name of the unit\n * @maxLength 80\n */\n name: string;\n /**\n * The day you would like to be billed for the Unit's Products (a value from 1 and 28)\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: OrganisationUnitPostBodyBodyDefaultProductPrivacy;\n};\n\nexport type PersonalUnitPutBodyBody = {\n /**\n * The day you would like to be billed for the Unit's Products (a value from 1 and 28)\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n};\n\n/**\n * The default product privacy setting for the Organisation\n */\nexport type OrganisationPostBodyBodyDefaultProductPrivacy = typeof OrganisationPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPostBodyBody = {\n /**\n * The name of the organisation\n * @maxLength 80\n */\n name: string;\n /** The name of the organisation owner. A user ID */\n owner: string;\n /** The default product privacy setting for the Organisation */\n default_product_privacy?: OrganisationPostBodyBodyDefaultProductPrivacy;\n};\n\nexport type AssetPostBodyBodyScope = typeof AssetPostBodyBodyScope[keyof typeof AssetPostBodyBodyScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetPostBodyBodyScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport type AssetPostBodyBody = {\n /**\n * The name of the asset. This must be unique within its scope. For example, only one asset can be called \"asset-1\" within a given Unit. Asset names must be valid RFC 1123 Label Names\n * @maxLength 80\n * @pattern ^[a-z0-9-]{1,63}$\n */\n name: string;\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n scope: AssetPostBodyBodyScope;\n /** The unique identity based on the Scope of the asset. For example, this will be the Unit ID if it's a UNIT. A scope_id is required if the scope is USER as it will be automatically set to your username. Global assets do not have a scope. */\n scope_id?: string;\n /** Is this a secret asset? */\n secret: boolean;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport type AssetPatchBodyBody = {\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport interface UserDetail {\n /** The user identity (username) */\n id: string;\n}\n\nexport interface UserAccountDetail {\n user: UserDetail;\n /** Whether the caller has admin privilege */\n caller_has_admin_privilege: boolean;\n /** The roles assigned to the user recognised by the Account Server */\n account_server_roles: string[];\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitDetailDefaultProductPrivacy = typeof UnitDetailDefaultProductPrivacy[keyof typeof UnitDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Unit's billing day */\n billing_day: number;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitDetailDefaultProductPrivacy;\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitAllDetailDefaultProductPrivacy = typeof UnitAllDetailDefaultProductPrivacy[keyof typeof UnitAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Unit's billing day */\n billing_day: number;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitAllDetailDefaultProductPrivacy;\n /** A list of users that are members of the Unit */\n users: UserDetail[];\n}\n\n/**\n * The kind of Service\n */\nexport type MerchantDetailKind = typeof MerchantDetailKind[keyof typeof MerchantDetailKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const MerchantDetailKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface MerchantDetail {\n /** The unique ID of the Service */\n id: number;\n created: string;\n /** The kind of Service */\n kind: MerchantDetailKind;\n /** The name assigned to the Service */\n name: string;\n /** The hostname used by the Service */\n api_hostname: string;\n}\n\nexport type MerchantGetResponse = MerchantDetail;\n\nexport interface MerchantsGetResponse {\n count?: number;\n /** The list of known Merchants\n */\n merchants: MerchantDetail[];\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationDetailDefaultProductPrivacy = typeof OrganisationDetailDefaultProductPrivacy[keyof typeof OrganisationDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationDetailDefaultProductPrivacy;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationAllDetailDefaultProductPrivacy = typeof OrganisationAllDetailDefaultProductPrivacy[keyof typeof OrganisationAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationAllDetailDefaultProductPrivacy;\n /** A list of users that are members of the Organisation */\n users: UserDetail[];\n}\n\n/**\n * The kind of service that can use the Product\n */\nexport type ProductTypeServiceKind = typeof ProductTypeServiceKind[keyof typeof ProductTypeServiceKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductTypeServiceKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProductType {\n /** A product type, this is a unique string amongst all types known to the Account Server */\n type: string;\n /** A product flavour. Not all types have a flavour, those that do have a type-specific flavour string */\n flavour?: string;\n /** The kind of service that can use the Product */\n service_kind?: ProductTypeServiceKind;\n}\n\nexport type ProductInstanceDetailCoins = {\n /** The number of coins used\n */\n used: number;\n};\n\nexport interface ProductInstanceDetail {\n coins: ProductInstanceDetailCoins;\n}\n\n/**\n * The Product Type flavour. Not all products have flavours\n\n */\nexport type ProductDetailFlavour = typeof ProductDetailFlavour[keyof typeof ProductDetailFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\n/**\n * The Product Type\n\n */\nexport type ProductDetailType = typeof ProductDetailType[keyof typeof ProductDetailType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductDetail {\n /** The Product ID\n */\n id: string;\n created: string;\n /** The Product Type\n */\n type: ProductDetailType;\n /** The Product Type flavour. Not all products have flavours\n */\n flavour?: ProductDetailFlavour;\n /** The name of the Product\n */\n name?: string;\n}\n\nexport interface ProductCoinsDetail {\n /** The billing allowance. When you exceed this during the current billing period the *cost multiplier* will increase */\n allowance: number;\n /** The limit on your billing period spend. You can exceed the allowance but you cannot exceed the spend limit. Once reached the dependent may be restricted */\n limit: number;\n /** The total number of coins consumed (in this billing period), excluding the coins that have been consumed for the current day */\n used: number;\n /** True if the product is operating at or beyond its coin limit. When it is authority to perform actions using the product are severely limited. */\n at_limit: boolean;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate: number;\n /** The predicted total billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction: number;\n /** The predicted storage contribution to the billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction_storage_contribution: number;\n /** The day of the month when the bill is due, and the end of the current billing period */\n billing_day: number;\n /** A multiplier applied to your coin usage within your allowance */\n allowance_multiplier: number;\n /** A multiplier that will be applied to coin used beyond your allowance */\n overspend_multiplier: number;\n /** The number of days remaining, in the current billing period */\n remaining_days: number;\n}\n\nexport interface ProductClaimDetail {\n /** The service-specific ID that is using this Subscription\n */\n id: string;\n /** A name for the service-specific ID\n */\n name?: string;\n}\n\nexport type ProductDmStorageDetailCoins = {\n /** The number of coins currently committed for the current day. This is added to the accumulated coins at the start of each day */\n used: number;\n /** The coin cost of a 'unit' of storage or part thereof. The unit size is defined in the storage section of the response */\n unit_cost: number;\n};\n\nexport type ProductDmStorageDetailSize = {\n /** The humanised size of the peak storage used for the current day. The value is reset at the start of each day */\n peak: string;\n /** The humanised size of the current storage used for the current day and used to calculate the 'burn rate' */\n current: string;\n /** The humanised storage unit. The cost of storage is based on the daily peak of the number of units (or part thereof) used */\n unit_size: string;\n /** The peak number of storage units used today */\n units_used: number;\n};\n\nexport interface ProductDmStorageDetail {\n size: ProductDmStorageDetailSize;\n coins: ProductDmStorageDetailCoins;\n}\n\nexport interface ProductDmProjectTier {\n product: ProductDetail;\n organisation: OrganisationAllDetail;\n unit: UnitAllDetail;\n storage: ProductDmStorageDetail;\n coins: ProductCoinsDetail;\n instance: ProductInstanceDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n claim?: ProductClaimDetail;\n}\n\nexport interface ProductDmStorage {\n product: ProductDetail;\n organisation: OrganisationAllDetail;\n unit: UnitAllDetail;\n storage: ProductDmStorageDetail;\n coins: ProductCoinsDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n}\n\nexport interface ChargeAdditionalData { [key: string]: unknown }\n\nexport interface StorageChargeItem {\n item_number: number;\n /** The date and time of the processing charge */\n date: string;\n /** The coin-cost of the storage */\n coins: string;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate?: string;\n /** The date when the charges concluded */\n closed?: string;\n additional_data?: ChargeAdditionalData;\n}\n\nexport interface StorageCharges {\n num_items: number;\n items: StorageChargeItem[];\n}\n\nexport interface ProcessingChargeItem {\n /** The charge record number */\n id: number;\n /** The most recent sequence number for this charge */\n sqn: number;\n name?: string;\n username: string;\n /** The date and time of the processing charge */\n timestamp: string;\n /** The coin-cost of the storage */\n coins: string;\n additional_data?: ChargeAdditionalData;\n}\n\nexport type ProcessingChargesMerchantKind = typeof ProcessingChargesMerchantKind[keyof typeof ProcessingChargesMerchantKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProcessingChargesMerchantKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProcessingCharges {\n merchant_name: string;\n merchant_kind: ProcessingChargesMerchantKind;\n merchant_api_hostname: string;\n /** The date when the process stopped */\n closed?: string;\n /** True if no further change to the charges can occur. Typically True after the charge has been closed for a pre-configured period of time. */\n final: boolean;\n /** True if charges were received after the charge record was finalised */\n post_final_charges?: boolean;\n charge: ProcessingChargeItem;\n}\n\nexport type AssetDetailScope = typeof AssetDetailScope[keyof typeof AssetDetailScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetDetailScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport interface AssetDetail {\n creator: string;\n id: string;\n name: string;\n scope: AssetDetailScope;\n scope_id: string;\n secret: boolean;\n disabled: boolean;\n content: string;\n created: string;\n content_modified?: string;\n description?: string;\n merchants: MerchantDetail[];\n}\n\nexport type UserAccountGetResponse = UserAccountDetail;\n\nexport interface UnitsGetResponse {\n /** A list of Units\n */\n units: OrganisationUnitsGetResponse[];\n}\n\nexport type UnitGetResponse = UnitAllDetail;\n\nexport interface UnitProductPostResponse {\n /** The Product's unique ID */\n id: string;\n}\n\n/**\n * The type of charge\n */\nexport type ChargeSummaryType = typeof ChargeSummaryType[keyof typeof ChargeSummaryType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ChargeSummaryType = {\n PROCESSING: 'PROCESSING',\n STORAGE: 'STORAGE',\n} as const;\n\nexport interface ChargeSummary {\n /** The type of charge */\n type: ChargeSummaryType;\n /** The cost, in coins of the charge */\n coins: string;\n}\n\nexport interface UnitProductChargeSummary {\n product_id: string;\n product_type: string;\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargeSummary {\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargesGetResponse {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n unit_id: string;\n name?: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n coins: string;\n count: number;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n summary: UnitChargeSummary;\n products: UnitProductChargeSummary[];\n}\n\n/**\n * The Unit's Product\n */\nexport type ProductUnitGetResponseProduct = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductUnitGetResponse {\n /** The Unit's Product */\n product: ProductUnitGetResponseProduct;\n}\n\nexport interface ProductsGetTypesResponse {\n /** The number of Product Types */\n count: number;\n /** All the Product Types you have access to */\n product_types: ProductType[];\n}\n\nexport type ProductsGetDefaultStorageCostDefaultStorageCost = {\n cost: string;\n units: string;\n description: string;\n};\n\nexport interface ProductsGetDefaultStorageCost {\n default_storage_cost: ProductsGetDefaultStorageCostDefaultStorageCost;\n}\n\nexport type ProductsGetResponseProductsItem = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductsGetResponse {\n count: number;\n /** All the Products you have access to */\n products: ProductsGetResponseProductsItem[];\n}\n\nexport type ProductChargesGetResponseProductType = typeof ProductChargesGetResponseProductType[keyof typeof ProductChargesGetResponseProductType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductChargesGetResponseProductType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductChargesGetResponse {\n product_id: string;\n product_type: ProductChargesGetResponseProductType;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n claim?: ProductClaimDetail;\n count: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n /** The total number of coins consumed by this product for the invoice period */\n coins: string;\n processing_charges: ProcessingCharges[];\n storage_charges: StorageCharges;\n}\n\nexport type OrganisationGetResponse = OrganisationAllDetail;\n\nexport interface OrganisationsGetResponse {\n count: number;\n /** A list of Organisations */\n organisations: OrganisationAllDetail[];\n}\n\nexport interface OrganisationUnitChargeSummary {\n unit_id: string;\n name: string;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n summary: ChargeSummary[];\n}\n\nexport interface OrganisationChargesGetResponse {\n organisation_id: string;\n name: string;\n coins: string;\n summary: ChargeSummary[];\n unit_charges: OrganisationUnitChargeSummary[];\n}\n\nexport interface OrganisationUnitsGetResponse {\n count?: number;\n organisation: OrganisationAllDetail;\n /** A list of Units\n */\n units: UnitAllDetail[];\n}\n\nexport interface OrganisationChargeSummary {\n organisation_id: string;\n name: string;\n summary: ChargeSummary[];\n}\n\nexport interface PersonalUnitPutResponse {\n /** The unit's Organisation. Used to identify the Default organisation */\n organisation_id: string;\n /** The unit's unique ID */\n id: string;\n}\n\nexport interface OrganisationUnitPostResponse {\n /** The unit's unique ID */\n id: string;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationGetDefaultResponseDefaultProductPrivacy = typeof OrganisationGetDefaultResponseDefaultProductPrivacy[keyof typeof OrganisationGetDefaultResponseDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationGetDefaultResponseDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationGetDefaultResponse {\n /** Whether the user making the API call is a member of the Default Organisation. Only admin users are members of the Default organisation */\n caller_is_member?: boolean;\n /** The Default Organisation ID\n */\n id?: string;\n /** The Default Organisation Name\n */\n name?: string;\n /** True if the Organisation is private. The Default organisation is always public, although it does not contain a membership (unless you're admin) and only houses Personal Units\n */\n private?: boolean;\n created?: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy?: OrganisationGetDefaultResponseDefaultProductPrivacy;\n}\n\nexport interface UsersGetResponse {\n count: number;\n organisation?: OrganisationDetail;\n unit?: UnitDetail;\n /** The list of Organisation Users\n */\n users: UserDetail[];\n}\n\nexport interface OrganisationPostResponse {\n /** The Organisation's unique ID */\n id: string;\n}\n\nexport interface StateGetVersionResponse {\n /** The Account Server version. This is guaranteed to be a valid semantic version for official (tagged) images. The version value format for unofficial images is a string but otherwise undefined\n */\n version: string;\n}\n\nexport interface EventStreamGetPostResponse {\n /** The EventStream ID */\n id: number;\n /** The EventStream location, a URL where events can be fetched. Typically a WebSocket. */\n location: string;\n}\n\nexport interface ChargesGetResponse {\n coins: string;\n count: number;\n summary: ChargeSummary[];\n organisation_charges: OrganisationChargeSummary[];\n}\n\nexport interface AssetPostResponse {\n /** The Asset ID\n */\n id: string;\n}\n\nexport interface AssetGetResponse {\n /** A list of Assets\n */\n assets: AssetDetail[];\n /** The number of Assets returned\n */\n count: number;\n}\n\nexport type AssetGetByIdResponse = AssetDetail;\n\nexport interface AsError {\n /** Brief error text that can be presented to the user */\n error: string;\n}\n\n"]}
1
+ {"version":3,"sources":["/home/runner/work/squonk2-account-server-js-client/squonk2-account-server-js-client/dist/index.cjs","../src/account-server-api.schemas.ts"],"names":[],"mappings":"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","file":"/home/runner/work/squonk2-account-server-js-client/squonk2-account-server-js-client/dist/index.cjs","sourcesContent":[null,"// @ts-nocheck\n/**\n * Generated by orval v7.4.1 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.2\n */\nexport type DetachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type AttachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type GetUnitsParams = {\n/**\n * An object name\n */\nname?: QNameParameter;\n};\n\nexport type GetOrganisationsParams = {\n/**\n * An object name\n */\nname?: QNameParameter;\n};\n\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QUntilParameter = string;\n\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QFromParameter = string;\n\nexport type GetProductChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetOrganisationChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\n/**\n * A User Identity\n */\nexport type QUserIdParameter = string;\n\n/**\n * A Product Identity\n */\nexport type QProductIdParameter = string;\n\n/**\n * A Unit Identity\n */\nexport type QUnitIdParameter = string;\n\n/**\n * An object name\n */\nexport type QNameParameter = string;\n\n/**\n * A Merchant Identity\n */\nexport type QMIdParameter = number;\n\n/**\n * An Organisation Identity\n */\nexport type QOrgIdParameter = string;\n\nexport type GetAssetParams = {\n/**\n * A User Identity\n */\nuser_id?: QUserIdParameter;\n/**\n * A Product Identity\n */\nproduct_id?: QProductIdParameter;\n/**\n * A Unit Identity\n */\nunit_id?: QUnitIdParameter;\n/**\n * An Organisation Identity\n */\norg_id?: QOrgIdParameter;\n};\n\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\nexport type QPbpParameter = number;\n\nexport type GetUnitChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type ProductPatchBodyBody = {\n /**\n * The name you want to give the Product\n * @maxLength 80\n */\n name?: string;\n /**\n * The Product's built-in coin allowance. Product allowances cannot be reduced\n * @minimum 1\n */\n allowance?: number;\n /**\n * The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. The existing product limit cannot be reduced\n * @minimum 1\n */\n limit?: number;\n};\n\n/**\n * The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products\n */\nexport type UnitProductPostBodyBodyFlavour = typeof UnitProductPostBodyBodyFlavour[keyof typeof UnitProductPostBodyBodyFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\n/**\n * The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products\n */\nexport type UnitProductPostBodyBodyType = typeof UnitProductPostBodyBodyType[keyof typeof UnitProductPostBodyBodyType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport type UnitProductPostBodyBody = {\n /**\n * The name you want to give the Product\n * @maxLength 80\n */\n name: string;\n /** The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products */\n type: UnitProductPostBodyBodyType;\n /** The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products */\n flavour?: UnitProductPostBodyBodyFlavour;\n /**\n * The Product's coin allowance. You must provide this for Storage products but you must not provide a value for Project Tier Products\n * @minimum 1\n */\n allowance?: number;\n /**\n * The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. You can provide this for Storage products but you must not provide a value for Project Tier Products\n * @minimum 1\n */\n limit?: number;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value\n */\nexport type UnitPatchBodyBodyDefaultProductPrivacy = typeof UnitPatchBodyBodyDefaultProductPrivacy[keyof typeof UnitPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type UnitPatchBodyBody = {\n /** The new name for the Unit */\n name?: string;\n /** The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: UnitPatchBodyBodyDefaultProductPrivacy;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units\n */\nexport type OrganisationPatchBodyBodyDefaultProductPrivacy = typeof OrganisationPatchBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPatchBodyBody = {\n /** The new name for the Organisational */\n name?: string;\n /** The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units */\n default_product_privacy?: OrganisationPatchBodyBodyDefaultProductPrivacy;\n};\n\n/**\n * The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value\n */\nexport type OrganisationUnitPostBodyBodyDefaultProductPrivacy = typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationUnitPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationUnitPostBodyBody = {\n /**\n * The name of the unit\n * @maxLength 80\n */\n name: string;\n /**\n * The day you would like to be billed for the Unit's Products (a value from 1 and 28)\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: OrganisationUnitPostBodyBodyDefaultProductPrivacy;\n};\n\nexport type PersonalUnitPutBodyBody = {\n /**\n * The day you would like to be billed for the Unit's Products (a value from 1 and 28)\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n};\n\n/**\n * The default product privacy setting for the Organisation\n */\nexport type OrganisationPostBodyBodyDefaultProductPrivacy = typeof OrganisationPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPostBodyBody = {\n /**\n * The name of the organisation\n * @maxLength 80\n */\n name: string;\n /** The name of the organisation owner. A user ID */\n owner: string;\n /** The default product privacy setting for the Organisation */\n default_product_privacy?: OrganisationPostBodyBodyDefaultProductPrivacy;\n};\n\nexport type AssetPostBodyBodyScope = typeof AssetPostBodyBodyScope[keyof typeof AssetPostBodyBodyScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetPostBodyBodyScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport type AssetPostBodyBody = {\n /**\n * The name of the asset. This must be unique within its scope. For example, only one asset can be called \"asset-1\" within a given Unit. Asset names must be valid RFC 1123 Label Names\n * @maxLength 80\n * @pattern ^[a-z0-9-]{1,63}$\n */\n name: string;\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n scope: AssetPostBodyBodyScope;\n /** The unique identity based on the Scope of the asset. For example, this will be the Unit ID if it's a UNIT. A scope_id is required if the scope is USER as it will be automatically set to your username. Global assets do not have a scope. */\n scope_id?: string;\n /** Is this a secret asset? */\n secret: boolean;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport type AssetPatchBodyBody = {\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport interface UserDetail {\n /** The user identity (username) */\n id: string;\n}\n\nexport interface UserAccountDetail {\n user: UserDetail;\n /** Whether the caller has admin privilege */\n caller_has_admin_privilege: boolean;\n /** The roles assigned to the user recognised by the Account Server */\n account_server_roles: string[];\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitDetailDefaultProductPrivacy = typeof UnitDetailDefaultProductPrivacy[keyof typeof UnitDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Unit's billing day */\n billing_day: number;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitDetailDefaultProductPrivacy;\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitAllDetailDefaultProductPrivacy = typeof UnitAllDetailDefaultProductPrivacy[keyof typeof UnitAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Unit's billing day */\n billing_day: number;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitAllDetailDefaultProductPrivacy;\n /** A list of users that are members of the Unit */\n users: UserDetail[];\n}\n\n/**\n * The kind of Service\n */\nexport type MerchantDetailKind = typeof MerchantDetailKind[keyof typeof MerchantDetailKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const MerchantDetailKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface MerchantDetail {\n /** The unique ID of the Service */\n id: number;\n created: string;\n /** The kind of Service */\n kind: MerchantDetailKind;\n /** The name assigned to the Service */\n name: string;\n /** The hostname used by the Service */\n api_hostname: string;\n}\n\nexport type MerchantGetResponse = MerchantDetail;\n\nexport interface MerchantsGetResponse {\n count?: number;\n /** The list of known Merchants\n */\n merchants: MerchantDetail[];\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationDetailDefaultProductPrivacy = typeof OrganisationDetailDefaultProductPrivacy[keyof typeof OrganisationDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationDetailDefaultProductPrivacy;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationAllDetailDefaultProductPrivacy = typeof OrganisationAllDetailDefaultProductPrivacy[keyof typeof OrganisationAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationAllDetailDefaultProductPrivacy;\n /** A list of users that are members of the Organisation */\n users: UserDetail[];\n}\n\n/**\n * The kind of service that can use the Product\n */\nexport type ProductTypeServiceKind = typeof ProductTypeServiceKind[keyof typeof ProductTypeServiceKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductTypeServiceKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProductType {\n /** A product type, this is a unique string amongst all types known to the Account Server */\n type: string;\n /** A product flavour. Not all types have a flavour, those that do have a type-specific flavour string */\n flavour?: string;\n /** The kind of service that can use the Product */\n service_kind?: ProductTypeServiceKind;\n}\n\nexport type ProductInstanceDetailCoins = {\n /** The number of coins used\n */\n used: number;\n};\n\nexport interface ProductInstanceDetail {\n coins: ProductInstanceDetailCoins;\n}\n\n/**\n * The Product Type flavour. Not all products have flavours\n\n */\nexport type ProductDetailFlavour = typeof ProductDetailFlavour[keyof typeof ProductDetailFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\n/**\n * The Product Type\n\n */\nexport type ProductDetailType = typeof ProductDetailType[keyof typeof ProductDetailType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductDetail {\n /** The Product ID\n */\n id: string;\n created: string;\n /** The Product Type\n */\n type: ProductDetailType;\n /** The Product Type flavour. Not all products have flavours\n */\n flavour?: ProductDetailFlavour;\n /** The name of the Product\n */\n name?: string;\n}\n\nexport interface ProductCoinsDetail {\n /** The billing allowance. When you exceed this during the current billing period the *cost multiplier* will increase */\n allowance: number;\n /** The limit on your billing period spend. You can exceed the allowance but you cannot exceed the spend limit. Once reached the dependent may be restricted */\n limit: number;\n /** The total number of coins consumed (in this billing period), excluding the coins that have been consumed for the current day */\n used: number;\n /** True if the product is operating at or beyond its coin limit. When it is authority to perform actions using the product are severely limited. */\n at_limit: boolean;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate: number;\n /** The predicted total billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction: number;\n /** The predicted storage contribution to the billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction_storage_contribution: number;\n /** The day of the month when the bill is due, and the end of the current billing period */\n billing_day: number;\n /** A multiplier applied to your coin usage within your allowance */\n allowance_multiplier: number;\n /** A multiplier that will be applied to coin used beyond your allowance */\n overspend_multiplier: number;\n /** The number of days remaining, in the current billing period */\n remaining_days: number;\n}\n\nexport interface ProductClaimDetail {\n /** The service-specific ID that is using this Subscription\n */\n id: string;\n /** A name for the service-specific ID\n */\n name?: string;\n}\n\nexport type ProductDmStorageDetailCoins = {\n /** The number of coins currently committed for the current day. This is added to the accumulated coins at the start of each day */\n used: number;\n /** The coin cost of a 'unit' of storage or part thereof. The unit size is defined in the storage section of the response */\n unit_cost: number;\n};\n\nexport type ProductDmStorageDetailSize = {\n /** The humanised size of the peak storage used for the current day. The value is reset at the start of each day */\n peak: string;\n /** The humanised size of the current storage used for the current day and used to calculate the 'burn rate' */\n current: string;\n /** The humanised storage unit. The cost of storage is based on the daily peak of the number of units (or part thereof) used */\n unit_size: string;\n /** The peak number of storage units used today */\n units_used: number;\n};\n\nexport interface ProductDmStorageDetail {\n size: ProductDmStorageDetailSize;\n coins: ProductDmStorageDetailCoins;\n}\n\nexport interface ProductDmProjectTier {\n product: ProductDetail;\n organisation: OrganisationAllDetail;\n unit: UnitAllDetail;\n storage: ProductDmStorageDetail;\n coins: ProductCoinsDetail;\n instance: ProductInstanceDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n claim?: ProductClaimDetail;\n}\n\nexport interface ProductDmStorage {\n product: ProductDetail;\n organisation: OrganisationAllDetail;\n unit: UnitAllDetail;\n storage: ProductDmStorageDetail;\n coins: ProductCoinsDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n}\n\nexport interface ChargeAdditionalData { [key: string]: unknown }\n\nexport interface StorageChargeItem {\n item_number: number;\n /** The date and time of the processing charge */\n date: string;\n /** The coin-cost of the storage */\n coins: string;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate?: string;\n /** The date when the charges concluded */\n closed?: string;\n additional_data?: ChargeAdditionalData;\n}\n\nexport interface StorageCharges {\n num_items: number;\n items: StorageChargeItem[];\n}\n\nexport interface ProcessingChargeItem {\n /** The charge record number */\n id: number;\n /** The most recent sequence number for this charge */\n sqn: number;\n name?: string;\n username: string;\n /** The date and time of the processing charge */\n timestamp: string;\n /** The coin-cost of the storage */\n coins: string;\n additional_data?: ChargeAdditionalData;\n}\n\nexport type ProcessingChargesMerchantKind = typeof ProcessingChargesMerchantKind[keyof typeof ProcessingChargesMerchantKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProcessingChargesMerchantKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProcessingCharges {\n merchant_name: string;\n merchant_kind: ProcessingChargesMerchantKind;\n merchant_api_hostname: string;\n /** The date when the process stopped */\n closed?: string;\n /** True if no further change to the charges can occur. Typically True after the charge has been closed for a pre-configured period of time. */\n final: boolean;\n /** True if charges were received after the charge record was finalised */\n post_final_charges?: boolean;\n charge: ProcessingChargeItem;\n}\n\nexport type AssetDetailScope = typeof AssetDetailScope[keyof typeof AssetDetailScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetDetailScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport interface AssetDetail {\n creator: string;\n id: string;\n name: string;\n scope: AssetDetailScope;\n scope_id: string;\n secret: boolean;\n disabled: boolean;\n content: string;\n created: string;\n content_modified?: string;\n description?: string;\n merchants: MerchantDetail[];\n}\n\nexport type UserAccountGetResponse = UserAccountDetail;\n\nexport interface UnitsGetResponse {\n /** A list of Units\n */\n units: OrganisationUnitsGetResponse[];\n}\n\nexport type UnitGetResponse = UnitAllDetail;\n\nexport interface UnitProductPostResponse {\n /** The Product's unique ID */\n id: string;\n}\n\n/**\n * The type of charge\n */\nexport type ChargeSummaryType = typeof ChargeSummaryType[keyof typeof ChargeSummaryType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ChargeSummaryType = {\n PROCESSING: 'PROCESSING',\n STORAGE: 'STORAGE',\n} as const;\n\nexport interface ChargeSummary {\n /** The type of charge */\n type: ChargeSummaryType;\n /** The cost, in coins of the charge */\n coins: string;\n}\n\nexport interface UnitProductChargeSummary {\n product_id: string;\n product_type: string;\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargeSummary {\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargesGetResponse {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n unit_id: string;\n name?: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n coins: string;\n count: number;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n summary: UnitChargeSummary;\n products: UnitProductChargeSummary[];\n}\n\n/**\n * The Unit's Product\n */\nexport type ProductUnitGetResponseProduct = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductUnitGetResponse {\n /** The Unit's Product */\n product: ProductUnitGetResponseProduct;\n}\n\nexport interface ProductsGetTypesResponse {\n /** The number of Product Types */\n count: number;\n /** All the Product Types you have access to */\n product_types: ProductType[];\n}\n\nexport type ProductsGetDefaultStorageCostDefaultStorageCost = {\n cost: string;\n units: string;\n description: string;\n};\n\nexport interface ProductsGetDefaultStorageCost {\n default_storage_cost: ProductsGetDefaultStorageCostDefaultStorageCost;\n}\n\nexport type ProductsGetResponseProductsItem = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductsGetResponse {\n count: number;\n /** All the Products you have access to */\n products: ProductsGetResponseProductsItem[];\n}\n\nexport type ProductChargesGetResponseProductType = typeof ProductChargesGetResponseProductType[keyof typeof ProductChargesGetResponseProductType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductChargesGetResponseProductType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductChargesGetResponse {\n product_id: string;\n product_type: ProductChargesGetResponseProductType;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n claim?: ProductClaimDetail;\n count: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n /** The total number of coins consumed by this product for the invoice period */\n coins: string;\n processing_charges: ProcessingCharges[];\n storage_charges: StorageCharges;\n}\n\nexport type OrganisationGetResponse = OrganisationAllDetail;\n\nexport interface OrganisationsGetResponse {\n count: number;\n /** A list of Organisations */\n organisations: OrganisationAllDetail[];\n}\n\nexport interface OrganisationUnitChargeSummary {\n unit_id: string;\n name: string;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n summary: ChargeSummary[];\n}\n\nexport interface OrganisationChargesGetResponse {\n organisation_id: string;\n name: string;\n coins: string;\n summary: ChargeSummary[];\n unit_charges: OrganisationUnitChargeSummary[];\n}\n\nexport interface OrganisationUnitsGetResponse {\n count?: number;\n organisation: OrganisationAllDetail;\n /** A list of Units\n */\n units: UnitAllDetail[];\n}\n\nexport interface OrganisationChargeSummary {\n organisation_id: string;\n name: string;\n summary: ChargeSummary[];\n}\n\nexport interface PersonalUnitPutResponse {\n /** The unit's Organisation. Used to identify the Default organisation */\n organisation_id: string;\n /** The unit's unique ID */\n id: string;\n}\n\nexport interface OrganisationUnitPostResponse {\n /** The unit's unique ID */\n id: string;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationGetDefaultResponseDefaultProductPrivacy = typeof OrganisationGetDefaultResponseDefaultProductPrivacy[keyof typeof OrganisationGetDefaultResponseDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationGetDefaultResponseDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationGetDefaultResponse {\n /** Whether the user making the API call is a member of the Default Organisation. Only admin users are members of the Default organisation */\n caller_is_member?: boolean;\n /** The Default Organisation ID\n */\n id?: string;\n /** The Default Organisation Name\n */\n name?: string;\n /** True if the Organisation is private. The Default organisation is always public, although it does not contain a membership (unless you're admin) and only houses Personal Units\n */\n private?: boolean;\n created?: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy?: OrganisationGetDefaultResponseDefaultProductPrivacy;\n}\n\nexport interface UsersGetResponse {\n count: number;\n organisation?: OrganisationDetail;\n unit?: UnitDetail;\n /** The list of Organisation Users\n */\n users: UserDetail[];\n}\n\nexport interface OrganisationPostResponse {\n /** The Organisation's unique ID */\n id: string;\n}\n\nexport interface StateGetVersionResponse {\n /** The Account Server version. This is guaranteed to be a valid semantic version for official (tagged) images. The version value format for unofficial images is a string but otherwise undefined\n */\n version: string;\n}\n\nexport interface EventStreamGetPostResponse {\n /** The EventStream ID */\n id: number;\n /** The Event Stream location. This will be a URL where events can be fetched. The protocol is typically a WebSocket, but the protocol is defined by the specific Event Stream Service that has been deployed. */\n location: string;\n}\n\nexport interface ChargesGetResponse {\n coins: string;\n count: number;\n summary: ChargeSummary[];\n organisation_charges: OrganisationChargeSummary[];\n}\n\nexport interface AssetPostResponse {\n /** The Asset ID\n */\n id: string;\n}\n\nexport interface AssetGetResponse {\n /** A list of Assets\n */\n assets: AssetDetail[];\n /** The number of Assets returned\n */\n count: number;\n}\n\nexport type AssetGetByIdResponse = AssetDetail;\n\nexport interface AsError {\n /** Brief error text that can be presented to the user */\n error: string;\n}\n\n"]}
package/index.d.cts CHANGED
@@ -884,7 +884,7 @@ interface StateGetVersionResponse {
884
884
  interface EventStreamGetPostResponse {
885
885
  /** The EventStream ID */
886
886
  id: number;
887
- /** The EventStream location, a URL where events can be fetched. Typically a WebSocket. */
887
+ /** The Event Stream location. This will be a URL where events can be fetched. The protocol is typically a WebSocket, but the protocol is defined by the specific Event Stream Service that has been deployed. */
888
888
  location: string;
889
889
  }
890
890
  interface ChargesGetResponse {
package/index.d.ts CHANGED
@@ -884,7 +884,7 @@ interface StateGetVersionResponse {
884
884
  interface EventStreamGetPostResponse {
885
885
  /** The EventStream ID */
886
886
  id: number;
887
- /** The EventStream location, a URL where events can be fetched. Typically a WebSocket. */
887
+ /** The Event Stream location. This will be a URL where events can be fetched. The protocol is typically a WebSocket, but the protocol is defined by the specific Event Stream Service that has been deployed. */
888
888
  location: string;
889
889
  }
890
890
  interface ChargesGetResponse {
package/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/account-server-api.schemas.ts"],"sourcesContent":["// @ts-nocheck\n/**\n * Generated by orval v7.4.1 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.2\n */\nexport type DetachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type AttachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type GetUnitsParams = {\n/**\n * An object name\n */\nname?: QNameParameter;\n};\n\nexport type GetOrganisationsParams = {\n/**\n * An object name\n */\nname?: QNameParameter;\n};\n\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QUntilParameter = string;\n\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QFromParameter = string;\n\nexport type GetProductChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetOrganisationChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\n/**\n * A User Identity\n */\nexport type QUserIdParameter = string;\n\n/**\n * A Product Identity\n */\nexport type QProductIdParameter = string;\n\n/**\n * A Unit Identity\n */\nexport type QUnitIdParameter = string;\n\n/**\n * An object name\n */\nexport type QNameParameter = string;\n\n/**\n * A Merchant Identity\n */\nexport type QMIdParameter = number;\n\n/**\n * An Organisation Identity\n */\nexport type QOrgIdParameter = string;\n\nexport type GetAssetParams = {\n/**\n * A User Identity\n */\nuser_id?: QUserIdParameter;\n/**\n * A Product Identity\n */\nproduct_id?: QProductIdParameter;\n/**\n * A Unit Identity\n */\nunit_id?: QUnitIdParameter;\n/**\n * An Organisation Identity\n */\norg_id?: QOrgIdParameter;\n};\n\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\nexport type QPbpParameter = number;\n\nexport type GetUnitChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type ProductPatchBodyBody = {\n /**\n * The name you want to give the Product\n * @maxLength 80\n */\n name?: string;\n /**\n * The Product's built-in coin allowance. Product allowances cannot be reduced\n * @minimum 1\n */\n allowance?: number;\n /**\n * The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. The existing product limit cannot be reduced\n * @minimum 1\n */\n limit?: number;\n};\n\n/**\n * The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products\n */\nexport type UnitProductPostBodyBodyFlavour = typeof UnitProductPostBodyBodyFlavour[keyof typeof UnitProductPostBodyBodyFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\n/**\n * The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products\n */\nexport type UnitProductPostBodyBodyType = typeof UnitProductPostBodyBodyType[keyof typeof UnitProductPostBodyBodyType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport type UnitProductPostBodyBody = {\n /**\n * The name you want to give the Product\n * @maxLength 80\n */\n name: string;\n /** The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products */\n type: UnitProductPostBodyBodyType;\n /** The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products */\n flavour?: UnitProductPostBodyBodyFlavour;\n /**\n * The Product's coin allowance. You must provide this for Storage products but you must not provide a value for Project Tier Products\n * @minimum 1\n */\n allowance?: number;\n /**\n * The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. You can provide this for Storage products but you must not provide a value for Project Tier Products\n * @minimum 1\n */\n limit?: number;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value\n */\nexport type UnitPatchBodyBodyDefaultProductPrivacy = typeof UnitPatchBodyBodyDefaultProductPrivacy[keyof typeof UnitPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type UnitPatchBodyBody = {\n /** The new name for the Unit */\n name?: string;\n /** The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: UnitPatchBodyBodyDefaultProductPrivacy;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units\n */\nexport type OrganisationPatchBodyBodyDefaultProductPrivacy = typeof OrganisationPatchBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPatchBodyBody = {\n /** The new name for the Organisational */\n name?: string;\n /** The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units */\n default_product_privacy?: OrganisationPatchBodyBodyDefaultProductPrivacy;\n};\n\n/**\n * The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value\n */\nexport type OrganisationUnitPostBodyBodyDefaultProductPrivacy = typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationUnitPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationUnitPostBodyBody = {\n /**\n * The name of the unit\n * @maxLength 80\n */\n name: string;\n /**\n * The day you would like to be billed for the Unit's Products (a value from 1 and 28)\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: OrganisationUnitPostBodyBodyDefaultProductPrivacy;\n};\n\nexport type PersonalUnitPutBodyBody = {\n /**\n * The day you would like to be billed for the Unit's Products (a value from 1 and 28)\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n};\n\n/**\n * The default product privacy setting for the Organisation\n */\nexport type OrganisationPostBodyBodyDefaultProductPrivacy = typeof OrganisationPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPostBodyBody = {\n /**\n * The name of the organisation\n * @maxLength 80\n */\n name: string;\n /** The name of the organisation owner. A user ID */\n owner: string;\n /** The default product privacy setting for the Organisation */\n default_product_privacy?: OrganisationPostBodyBodyDefaultProductPrivacy;\n};\n\nexport type AssetPostBodyBodyScope = typeof AssetPostBodyBodyScope[keyof typeof AssetPostBodyBodyScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetPostBodyBodyScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport type AssetPostBodyBody = {\n /**\n * The name of the asset. This must be unique within its scope. For example, only one asset can be called \"asset-1\" within a given Unit. Asset names must be valid RFC 1123 Label Names\n * @maxLength 80\n * @pattern ^[a-z0-9-]{1,63}$\n */\n name: string;\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n scope: AssetPostBodyBodyScope;\n /** The unique identity based on the Scope of the asset. For example, this will be the Unit ID if it's a UNIT. A scope_id is required if the scope is USER as it will be automatically set to your username. Global assets do not have a scope. */\n scope_id?: string;\n /** Is this a secret asset? */\n secret: boolean;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport type AssetPatchBodyBody = {\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport interface UserDetail {\n /** The user identity (username) */\n id: string;\n}\n\nexport interface UserAccountDetail {\n user: UserDetail;\n /** Whether the caller has admin privilege */\n caller_has_admin_privilege: boolean;\n /** The roles assigned to the user recognised by the Account Server */\n account_server_roles: string[];\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitDetailDefaultProductPrivacy = typeof UnitDetailDefaultProductPrivacy[keyof typeof UnitDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Unit's billing day */\n billing_day: number;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitDetailDefaultProductPrivacy;\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitAllDetailDefaultProductPrivacy = typeof UnitAllDetailDefaultProductPrivacy[keyof typeof UnitAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Unit's billing day */\n billing_day: number;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitAllDetailDefaultProductPrivacy;\n /** A list of users that are members of the Unit */\n users: UserDetail[];\n}\n\n/**\n * The kind of Service\n */\nexport type MerchantDetailKind = typeof MerchantDetailKind[keyof typeof MerchantDetailKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const MerchantDetailKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface MerchantDetail {\n /** The unique ID of the Service */\n id: number;\n created: string;\n /** The kind of Service */\n kind: MerchantDetailKind;\n /** The name assigned to the Service */\n name: string;\n /** The hostname used by the Service */\n api_hostname: string;\n}\n\nexport type MerchantGetResponse = MerchantDetail;\n\nexport interface MerchantsGetResponse {\n count?: number;\n /** The list of known Merchants\n */\n merchants: MerchantDetail[];\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationDetailDefaultProductPrivacy = typeof OrganisationDetailDefaultProductPrivacy[keyof typeof OrganisationDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationDetailDefaultProductPrivacy;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationAllDetailDefaultProductPrivacy = typeof OrganisationAllDetailDefaultProductPrivacy[keyof typeof OrganisationAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationAllDetailDefaultProductPrivacy;\n /** A list of users that are members of the Organisation */\n users: UserDetail[];\n}\n\n/**\n * The kind of service that can use the Product\n */\nexport type ProductTypeServiceKind = typeof ProductTypeServiceKind[keyof typeof ProductTypeServiceKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductTypeServiceKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProductType {\n /** A product type, this is a unique string amongst all types known to the Account Server */\n type: string;\n /** A product flavour. Not all types have a flavour, those that do have a type-specific flavour string */\n flavour?: string;\n /** The kind of service that can use the Product */\n service_kind?: ProductTypeServiceKind;\n}\n\nexport type ProductInstanceDetailCoins = {\n /** The number of coins used\n */\n used: number;\n};\n\nexport interface ProductInstanceDetail {\n coins: ProductInstanceDetailCoins;\n}\n\n/**\n * The Product Type flavour. Not all products have flavours\n\n */\nexport type ProductDetailFlavour = typeof ProductDetailFlavour[keyof typeof ProductDetailFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\n/**\n * The Product Type\n\n */\nexport type ProductDetailType = typeof ProductDetailType[keyof typeof ProductDetailType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductDetail {\n /** The Product ID\n */\n id: string;\n created: string;\n /** The Product Type\n */\n type: ProductDetailType;\n /** The Product Type flavour. Not all products have flavours\n */\n flavour?: ProductDetailFlavour;\n /** The name of the Product\n */\n name?: string;\n}\n\nexport interface ProductCoinsDetail {\n /** The billing allowance. When you exceed this during the current billing period the *cost multiplier* will increase */\n allowance: number;\n /** The limit on your billing period spend. You can exceed the allowance but you cannot exceed the spend limit. Once reached the dependent may be restricted */\n limit: number;\n /** The total number of coins consumed (in this billing period), excluding the coins that have been consumed for the current day */\n used: number;\n /** True if the product is operating at or beyond its coin limit. When it is authority to perform actions using the product are severely limited. */\n at_limit: boolean;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate: number;\n /** The predicted total billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction: number;\n /** The predicted storage contribution to the billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction_storage_contribution: number;\n /** The day of the month when the bill is due, and the end of the current billing period */\n billing_day: number;\n /** A multiplier applied to your coin usage within your allowance */\n allowance_multiplier: number;\n /** A multiplier that will be applied to coin used beyond your allowance */\n overspend_multiplier: number;\n /** The number of days remaining, in the current billing period */\n remaining_days: number;\n}\n\nexport interface ProductClaimDetail {\n /** The service-specific ID that is using this Subscription\n */\n id: string;\n /** A name for the service-specific ID\n */\n name?: string;\n}\n\nexport type ProductDmStorageDetailCoins = {\n /** The number of coins currently committed for the current day. This is added to the accumulated coins at the start of each day */\n used: number;\n /** The coin cost of a 'unit' of storage or part thereof. The unit size is defined in the storage section of the response */\n unit_cost: number;\n};\n\nexport type ProductDmStorageDetailSize = {\n /** The humanised size of the peak storage used for the current day. The value is reset at the start of each day */\n peak: string;\n /** The humanised size of the current storage used for the current day and used to calculate the 'burn rate' */\n current: string;\n /** The humanised storage unit. The cost of storage is based on the daily peak of the number of units (or part thereof) used */\n unit_size: string;\n /** The peak number of storage units used today */\n units_used: number;\n};\n\nexport interface ProductDmStorageDetail {\n size: ProductDmStorageDetailSize;\n coins: ProductDmStorageDetailCoins;\n}\n\nexport interface ProductDmProjectTier {\n product: ProductDetail;\n organisation: OrganisationAllDetail;\n unit: UnitAllDetail;\n storage: ProductDmStorageDetail;\n coins: ProductCoinsDetail;\n instance: ProductInstanceDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n claim?: ProductClaimDetail;\n}\n\nexport interface ProductDmStorage {\n product: ProductDetail;\n organisation: OrganisationAllDetail;\n unit: UnitAllDetail;\n storage: ProductDmStorageDetail;\n coins: ProductCoinsDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n}\n\nexport interface ChargeAdditionalData { [key: string]: unknown }\n\nexport interface StorageChargeItem {\n item_number: number;\n /** The date and time of the processing charge */\n date: string;\n /** The coin-cost of the storage */\n coins: string;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate?: string;\n /** The date when the charges concluded */\n closed?: string;\n additional_data?: ChargeAdditionalData;\n}\n\nexport interface StorageCharges {\n num_items: number;\n items: StorageChargeItem[];\n}\n\nexport interface ProcessingChargeItem {\n /** The charge record number */\n id: number;\n /** The most recent sequence number for this charge */\n sqn: number;\n name?: string;\n username: string;\n /** The date and time of the processing charge */\n timestamp: string;\n /** The coin-cost of the storage */\n coins: string;\n additional_data?: ChargeAdditionalData;\n}\n\nexport type ProcessingChargesMerchantKind = typeof ProcessingChargesMerchantKind[keyof typeof ProcessingChargesMerchantKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProcessingChargesMerchantKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProcessingCharges {\n merchant_name: string;\n merchant_kind: ProcessingChargesMerchantKind;\n merchant_api_hostname: string;\n /** The date when the process stopped */\n closed?: string;\n /** True if no further change to the charges can occur. Typically True after the charge has been closed for a pre-configured period of time. */\n final: boolean;\n /** True if charges were received after the charge record was finalised */\n post_final_charges?: boolean;\n charge: ProcessingChargeItem;\n}\n\nexport type AssetDetailScope = typeof AssetDetailScope[keyof typeof AssetDetailScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetDetailScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport interface AssetDetail {\n creator: string;\n id: string;\n name: string;\n scope: AssetDetailScope;\n scope_id: string;\n secret: boolean;\n disabled: boolean;\n content: string;\n created: string;\n content_modified?: string;\n description?: string;\n merchants: MerchantDetail[];\n}\n\nexport type UserAccountGetResponse = UserAccountDetail;\n\nexport interface UnitsGetResponse {\n /** A list of Units\n */\n units: OrganisationUnitsGetResponse[];\n}\n\nexport type UnitGetResponse = UnitAllDetail;\n\nexport interface UnitProductPostResponse {\n /** The Product's unique ID */\n id: string;\n}\n\n/**\n * The type of charge\n */\nexport type ChargeSummaryType = typeof ChargeSummaryType[keyof typeof ChargeSummaryType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ChargeSummaryType = {\n PROCESSING: 'PROCESSING',\n STORAGE: 'STORAGE',\n} as const;\n\nexport interface ChargeSummary {\n /** The type of charge */\n type: ChargeSummaryType;\n /** The cost, in coins of the charge */\n coins: string;\n}\n\nexport interface UnitProductChargeSummary {\n product_id: string;\n product_type: string;\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargeSummary {\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargesGetResponse {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n unit_id: string;\n name?: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n coins: string;\n count: number;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n summary: UnitChargeSummary;\n products: UnitProductChargeSummary[];\n}\n\n/**\n * The Unit's Product\n */\nexport type ProductUnitGetResponseProduct = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductUnitGetResponse {\n /** The Unit's Product */\n product: ProductUnitGetResponseProduct;\n}\n\nexport interface ProductsGetTypesResponse {\n /** The number of Product Types */\n count: number;\n /** All the Product Types you have access to */\n product_types: ProductType[];\n}\n\nexport type ProductsGetDefaultStorageCostDefaultStorageCost = {\n cost: string;\n units: string;\n description: string;\n};\n\nexport interface ProductsGetDefaultStorageCost {\n default_storage_cost: ProductsGetDefaultStorageCostDefaultStorageCost;\n}\n\nexport type ProductsGetResponseProductsItem = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductsGetResponse {\n count: number;\n /** All the Products you have access to */\n products: ProductsGetResponseProductsItem[];\n}\n\nexport type ProductChargesGetResponseProductType = typeof ProductChargesGetResponseProductType[keyof typeof ProductChargesGetResponseProductType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductChargesGetResponseProductType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductChargesGetResponse {\n product_id: string;\n product_type: ProductChargesGetResponseProductType;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n claim?: ProductClaimDetail;\n count: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n /** The total number of coins consumed by this product for the invoice period */\n coins: string;\n processing_charges: ProcessingCharges[];\n storage_charges: StorageCharges;\n}\n\nexport type OrganisationGetResponse = OrganisationAllDetail;\n\nexport interface OrganisationsGetResponse {\n count: number;\n /** A list of Organisations */\n organisations: OrganisationAllDetail[];\n}\n\nexport interface OrganisationUnitChargeSummary {\n unit_id: string;\n name: string;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n summary: ChargeSummary[];\n}\n\nexport interface OrganisationChargesGetResponse {\n organisation_id: string;\n name: string;\n coins: string;\n summary: ChargeSummary[];\n unit_charges: OrganisationUnitChargeSummary[];\n}\n\nexport interface OrganisationUnitsGetResponse {\n count?: number;\n organisation: OrganisationAllDetail;\n /** A list of Units\n */\n units: UnitAllDetail[];\n}\n\nexport interface OrganisationChargeSummary {\n organisation_id: string;\n name: string;\n summary: ChargeSummary[];\n}\n\nexport interface PersonalUnitPutResponse {\n /** The unit's Organisation. Used to identify the Default organisation */\n organisation_id: string;\n /** The unit's unique ID */\n id: string;\n}\n\nexport interface OrganisationUnitPostResponse {\n /** The unit's unique ID */\n id: string;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationGetDefaultResponseDefaultProductPrivacy = typeof OrganisationGetDefaultResponseDefaultProductPrivacy[keyof typeof OrganisationGetDefaultResponseDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationGetDefaultResponseDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationGetDefaultResponse {\n /** Whether the user making the API call is a member of the Default Organisation. Only admin users are members of the Default organisation */\n caller_is_member?: boolean;\n /** The Default Organisation ID\n */\n id?: string;\n /** The Default Organisation Name\n */\n name?: string;\n /** True if the Organisation is private. The Default organisation is always public, although it does not contain a membership (unless you're admin) and only houses Personal Units\n */\n private?: boolean;\n created?: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy?: OrganisationGetDefaultResponseDefaultProductPrivacy;\n}\n\nexport interface UsersGetResponse {\n count: number;\n organisation?: OrganisationDetail;\n unit?: UnitDetail;\n /** The list of Organisation Users\n */\n users: UserDetail[];\n}\n\nexport interface OrganisationPostResponse {\n /** The Organisation's unique ID */\n id: string;\n}\n\nexport interface StateGetVersionResponse {\n /** The Account Server version. This is guaranteed to be a valid semantic version for official (tagged) images. The version value format for unofficial images is a string but otherwise undefined\n */\n version: string;\n}\n\nexport interface EventStreamGetPostResponse {\n /** The EventStream ID */\n id: number;\n /** The EventStream location, a URL where events can be fetched. Typically a WebSocket. */\n location: string;\n}\n\nexport interface ChargesGetResponse {\n coins: string;\n count: number;\n summary: ChargeSummary[];\n organisation_charges: OrganisationChargeSummary[];\n}\n\nexport interface AssetPostResponse {\n /** The Asset ID\n */\n id: string;\n}\n\nexport interface AssetGetResponse {\n /** A list of Assets\n */\n assets: AssetDetail[];\n /** The number of Assets returned\n */\n count: number;\n}\n\nexport type AssetGetByIdResponse = AssetDetail;\n\nexport interface AsError {\n /** Brief error text that can be presented to the user */\n error: string;\n}\n\n"],"mappings":";;;;;;;;AA4LO,IAAM,iCAAiC;AAAA,EAC5C,YAAY;AAAA,EACZ,QAAQ;AAAA,EACR,QAAQ;AAAA,EACR,MAAM;AACR;AAWO,IAAM,8BAA8B;AAAA,EACzC,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AAmCO,IAAM,yCAAyC;AAAA,EACpD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAoBO,IAAM,iDAAiD;AAAA,EAC5D,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAkBO,IAAM,oDAAoD;AAAA,EAC/D,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAkCO,IAAM,gDAAgD;AAAA,EAC3D,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAkBO,IAAM,yBAAyB;AAAA,EACpC,MAAM;AAAA,EACN,SAAS;AAAA,EACT,MAAM;AAAA,EACN,cAAc;AAAA,EACd,QAAQ;AACV;AAmDO,IAAM,kCAAkC;AAAA,EAC7C,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AA2BO,IAAM,qCAAqC;AAAA,EAChD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AA6BO,IAAM,qBAAqB;AAAA,EAChC,cAAc;AAChB;AA8BO,IAAM,0CAA0C;AAAA,EACrD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAyBO,IAAM,6CAA6C;AAAA,EACxD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AA2BO,IAAM,yBAAyB;AAAA,EACpC,cAAc;AAChB;AA6BO,IAAM,uBAAuB;AAAA,EAClC,YAAY;AAAA,EACZ,QAAQ;AAAA,EACR,QAAQ;AAAA,EACR,MAAM;AACR;AAUO,IAAM,oBAAoB;AAAA,EAC/B,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AAuIO,IAAM,gCAAgC;AAAA,EAC3C,cAAc;AAChB;AAmBO,IAAM,mBAAmB;AAAA,EAC9B,MAAM;AAAA,EACN,SAAS;AAAA,EACT,MAAM;AAAA,EACN,cAAc;AAAA,EACd,QAAQ;AACV;AAuCO,IAAM,oBAAoB;AAAA,EAC/B,YAAY;AAAA,EACZ,SAAS;AACX;AAmFO,IAAM,uCAAuC;AAAA,EAClD,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AAwFO,IAAM,sDAAsD;AAAA,EACjE,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;","names":[]}
1
+ {"version":3,"sources":["../src/account-server-api.schemas.ts"],"sourcesContent":["// @ts-nocheck\n/**\n * Generated by orval v7.4.1 🍺\n * Do not edit manually.\n * Account Server API\n * The Informatics Matters Account Server API.\n\nA service that provides access to the Account Server, which gives *registered* users access to and management of **Organisations**, **Units**, **Products**, **Users**, and **Assets**.\n\n * OpenAPI spec version: 4.2\n */\nexport type DetachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type AttachAssetParams = {\n/**\n * A Merchant Identity\n */\nm_id?: QMIdParameter;\n};\n\nexport type GetUnitsParams = {\n/**\n * An object name\n */\nname?: QNameParameter;\n};\n\nexport type GetOrganisationsParams = {\n/**\n * An object name\n */\nname?: QNameParameter;\n};\n\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QUntilParameter = string;\n\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nexport type QFromParameter = string;\n\nexport type GetProductChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetOrganisationChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type GetChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\n/**\n * A User Identity\n */\nexport type QUserIdParameter = string;\n\n/**\n * A Product Identity\n */\nexport type QProductIdParameter = string;\n\n/**\n * A Unit Identity\n */\nexport type QUnitIdParameter = string;\n\n/**\n * An object name\n */\nexport type QNameParameter = string;\n\n/**\n * A Merchant Identity\n */\nexport type QMIdParameter = number;\n\n/**\n * An Organisation Identity\n */\nexport type QOrgIdParameter = string;\n\nexport type GetAssetParams = {\n/**\n * A User Identity\n */\nuser_id?: QUserIdParameter;\n/**\n * A Product Identity\n */\nproduct_id?: QProductIdParameter;\n/**\n * A Unit Identity\n */\nunit_id?: QUnitIdParameter;\n/**\n * An Organisation Identity\n */\norg_id?: QOrgIdParameter;\n};\n\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\nexport type QPbpParameter = number;\n\nexport type GetUnitChargesParams = {\n/**\n * A date from which to retrieve assets. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs on ar after this date will be returned. UTC is assumed if no timezone is provided\n */\nfrom?: QFromParameter;\n/**\n * A date where assets prior to this will be returned. This can be a date-time string but it is interpreted as a date, i.e. `2020-01-01T00:00:00Z` is interpreted as `2020-01-01`. Any asset that occurs prior this date will be returned. UTC is assumed if no timezone is provided\n */\nuntil?: QUntilParameter;\n/**\n * A charge Prior Billing Period, 0 implies \"current\" and -23 is for the period 23 months ago.\n */\npbp?: QPbpParameter;\n};\n\nexport type ProductPatchBodyBody = {\n /**\n * The name you want to give the Product\n * @maxLength 80\n */\n name?: string;\n /**\n * The Product's built-in coin allowance. Product allowances cannot be reduced\n * @minimum 1\n */\n allowance?: number;\n /**\n * The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. The existing product limit cannot be reduced\n * @minimum 1\n */\n limit?: number;\n};\n\n/**\n * The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products\n */\nexport type UnitProductPostBodyBodyFlavour = typeof UnitProductPostBodyBodyFlavour[keyof typeof UnitProductPostBodyBodyFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\n/**\n * The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products\n */\nexport type UnitProductPostBodyBodyType = typeof UnitProductPostBodyBodyType[keyof typeof UnitProductPostBodyBodyType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitProductPostBodyBodyType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport type UnitProductPostBodyBody = {\n /**\n * The name you want to give the Product\n * @maxLength 80\n */\n name: string;\n /** The Type of Product. Storage subscriptions require an **Allowance** to be defined and the **Flavour** must not be provided.\n\nProject Tier subscriptions have built-in allowances and Limits so you must not provide values for these for these products */\n type: UnitProductPostBodyBodyType;\n /** The Flavour of the Product. Used only for Project Tier Products. Do not set this for Storage products */\n flavour?: UnitProductPostBodyBodyFlavour;\n /**\n * The Product's coin allowance. You must provide this for Storage products but you must not provide a value for Project Tier Products\n * @minimum 1\n */\n allowance?: number;\n /**\n * The Product's built-in coin limit. If set it must not be less than the allowance. If not set the allowance is used. You can provide this for Storage products but you must not provide a value for Project Tier Products\n * @minimum 1\n */\n limit?: number;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value\n */\nexport type UnitPatchBodyBodyDefaultProductPrivacy = typeof UnitPatchBodyBodyDefaultProductPrivacy[keyof typeof UnitPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type UnitPatchBodyBody = {\n /** The new name for the Unit */\n name?: string;\n /** The new default **Product** privacy applied to all products that belong to this Unit. Privacy is also controlled at the **Organisation** level. As an example, the Unit can declare its Products to be `DEFAULT_PRIVATE`, but the Organisation can declare its value to be `DEFAULT_PUBLIC`.\n\nWhether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: UnitPatchBodyBodyDefaultProductPrivacy;\n};\n\n/**\n * The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units\n */\nexport type OrganisationPatchBodyBodyDefaultProductPrivacy = typeof OrganisationPatchBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPatchBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPatchBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPatchBodyBody = {\n /** The new name for the Organisational */\n name?: string;\n /** The new default **Product** privacy applied to all products that belong to this Organisation. Privacy is also controlled at the **Unit** level. As an example the Organisation level privacy can be `DEFAULT_PRIVATE`, but the unit can declare its Products to be `ALWAYS_PRIVATE`.\n\nWhether the privacy can be honoured will depend on the value in any of the organisation's existing units */\n default_product_privacy?: OrganisationPatchBodyBodyDefaultProductPrivacy;\n};\n\n/**\n * The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value\n */\nexport type OrganisationUnitPostBodyBodyDefaultProductPrivacy = typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationUnitPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationUnitPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationUnitPostBodyBody = {\n /**\n * The name of the unit\n * @maxLength 80\n */\n name: string;\n /**\n * The day you would like to be billed for the Unit's Products (a value from 1 and 28)\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The default product privacy setting for products in the unit. Whether the privacy can be honoured will depend on the organisation's value */\n default_product_privacy?: OrganisationUnitPostBodyBodyDefaultProductPrivacy;\n};\n\nexport type PersonalUnitPutBodyBody = {\n /**\n * The day you would like to be billed for the Unit's Products (a value from 1 and 28)\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n};\n\n/**\n * The default product privacy setting for the Organisation\n */\nexport type OrganisationPostBodyBodyDefaultProductPrivacy = typeof OrganisationPostBodyBodyDefaultProductPrivacy[keyof typeof OrganisationPostBodyBodyDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationPostBodyBodyDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport type OrganisationPostBodyBody = {\n /**\n * The name of the organisation\n * @maxLength 80\n */\n name: string;\n /** The name of the organisation owner. A user ID */\n owner: string;\n /** The default product privacy setting for the Organisation */\n default_product_privacy?: OrganisationPostBodyBodyDefaultProductPrivacy;\n};\n\nexport type AssetPostBodyBodyScope = typeof AssetPostBodyBodyScope[keyof typeof AssetPostBodyBodyScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetPostBodyBodyScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport type AssetPostBodyBody = {\n /**\n * The name of the asset. This must be unique within its scope. For example, only one asset can be called \"asset-1\" within a given Unit. Asset names must be valid RFC 1123 Label Names\n * @maxLength 80\n * @pattern ^[a-z0-9-]{1,63}$\n */\n name: string;\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n scope: AssetPostBodyBodyScope;\n /** The unique identity based on the Scope of the asset. For example, this will be the Unit ID if it's a UNIT. A scope_id is required if the scope is USER as it will be automatically set to your username. Global assets do not have a scope. */\n scope_id?: string;\n /** Is this a secret asset? */\n secret: boolean;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport type AssetPatchBodyBody = {\n /** A file containing the content for the asset. You must provide a value here or in content_string */\n content_file?: Blob;\n /** The textual content of the asset. You must provide a value here or in content_file */\n content_string?: string;\n /** An optional description for the Asset */\n description?: string;\n};\n\nexport interface UserDetail {\n /** The user identity (username) */\n id: string;\n}\n\nexport interface UserAccountDetail {\n user: UserDetail;\n /** Whether the caller has admin privilege */\n caller_has_admin_privilege: boolean;\n /** The roles assigned to the user recognised by the Account Server */\n account_server_roles: string[];\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitDetailDefaultProductPrivacy = typeof UnitDetailDefaultProductPrivacy[keyof typeof UnitDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Unit's billing day */\n billing_day: number;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitDetailDefaultProductPrivacy;\n}\n\n/**\n * The Unit's default product privacy setting\n */\nexport type UnitAllDetailDefaultProductPrivacy = typeof UnitAllDetailDefaultProductPrivacy[keyof typeof UnitAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const UnitAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface UnitAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Unit's unique identity */\n id: string;\n /** The Unit's name */\n name: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Unit's billing day */\n billing_day: number;\n /** The Unit's default product privacy setting */\n default_product_privacy: UnitAllDetailDefaultProductPrivacy;\n /** A list of users that are members of the Unit */\n users: UserDetail[];\n}\n\n/**\n * The kind of Service\n */\nexport type MerchantDetailKind = typeof MerchantDetailKind[keyof typeof MerchantDetailKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const MerchantDetailKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface MerchantDetail {\n /** The unique ID of the Service */\n id: number;\n created: string;\n /** The kind of Service */\n kind: MerchantDetailKind;\n /** The name assigned to the Service */\n name: string;\n /** The hostname used by the Service */\n api_hostname: string;\n}\n\nexport type MerchantGetResponse = MerchantDetail;\n\nexport interface MerchantsGetResponse {\n count?: number;\n /** The list of known Merchants\n */\n merchants: MerchantDetail[];\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationDetailDefaultProductPrivacy = typeof OrganisationDetailDefaultProductPrivacy[keyof typeof OrganisationDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationDetailDefaultProductPrivacy;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationAllDetailDefaultProductPrivacy = typeof OrganisationAllDetailDefaultProductPrivacy[keyof typeof OrganisationAllDetailDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationAllDetailDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationAllDetail {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n /** The Organisation's unique ID */\n id: string;\n /** The Organisation's name */\n name: string;\n /** The username of the Organisation's owner. Not all Organisations have an owner. The Default Organisation has no owner. */\n owner_id?: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy: OrganisationAllDetailDefaultProductPrivacy;\n /** A list of users that are members of the Organisation */\n users: UserDetail[];\n}\n\n/**\n * The kind of service that can use the Product\n */\nexport type ProductTypeServiceKind = typeof ProductTypeServiceKind[keyof typeof ProductTypeServiceKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductTypeServiceKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProductType {\n /** A product type, this is a unique string amongst all types known to the Account Server */\n type: string;\n /** A product flavour. Not all types have a flavour, those that do have a type-specific flavour string */\n flavour?: string;\n /** The kind of service that can use the Product */\n service_kind?: ProductTypeServiceKind;\n}\n\nexport type ProductInstanceDetailCoins = {\n /** The number of coins used\n */\n used: number;\n};\n\nexport interface ProductInstanceDetail {\n coins: ProductInstanceDetailCoins;\n}\n\n/**\n * The Product Type flavour. Not all products have flavours\n\n */\nexport type ProductDetailFlavour = typeof ProductDetailFlavour[keyof typeof ProductDetailFlavour];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailFlavour = {\n EVALUATION: 'EVALUATION',\n BRONZE: 'BRONZE',\n SILVER: 'SILVER',\n GOLD: 'GOLD',\n} as const;\n\n/**\n * The Product Type\n\n */\nexport type ProductDetailType = typeof ProductDetailType[keyof typeof ProductDetailType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductDetailType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductDetail {\n /** The Product ID\n */\n id: string;\n created: string;\n /** The Product Type\n */\n type: ProductDetailType;\n /** The Product Type flavour. Not all products have flavours\n */\n flavour?: ProductDetailFlavour;\n /** The name of the Product\n */\n name?: string;\n}\n\nexport interface ProductCoinsDetail {\n /** The billing allowance. When you exceed this during the current billing period the *cost multiplier* will increase */\n allowance: number;\n /** The limit on your billing period spend. You can exceed the allowance but you cannot exceed the spend limit. Once reached the dependent may be restricted */\n limit: number;\n /** The total number of coins consumed (in this billing period), excluding the coins that have been consumed for the current day */\n used: number;\n /** True if the product is operating at or beyond its coin limit. When it is authority to perform actions using the product are severely limited. */\n at_limit: boolean;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate: number;\n /** The predicted total billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction: number;\n /** The predicted storage contribution to the billing period amount, if costs continue at the current burn rate until the end of the billing period. This is an estimate */\n billing_prediction_storage_contribution: number;\n /** The day of the month when the bill is due, and the end of the current billing period */\n billing_day: number;\n /** A multiplier applied to your coin usage within your allowance */\n allowance_multiplier: number;\n /** A multiplier that will be applied to coin used beyond your allowance */\n overspend_multiplier: number;\n /** The number of days remaining, in the current billing period */\n remaining_days: number;\n}\n\nexport interface ProductClaimDetail {\n /** The service-specific ID that is using this Subscription\n */\n id: string;\n /** A name for the service-specific ID\n */\n name?: string;\n}\n\nexport type ProductDmStorageDetailCoins = {\n /** The number of coins currently committed for the current day. This is added to the accumulated coins at the start of each day */\n used: number;\n /** The coin cost of a 'unit' of storage or part thereof. The unit size is defined in the storage section of the response */\n unit_cost: number;\n};\n\nexport type ProductDmStorageDetailSize = {\n /** The humanised size of the peak storage used for the current day. The value is reset at the start of each day */\n peak: string;\n /** The humanised size of the current storage used for the current day and used to calculate the 'burn rate' */\n current: string;\n /** The humanised storage unit. The cost of storage is based on the daily peak of the number of units (or part thereof) used */\n unit_size: string;\n /** The peak number of storage units used today */\n units_used: number;\n};\n\nexport interface ProductDmStorageDetail {\n size: ProductDmStorageDetailSize;\n coins: ProductDmStorageDetailCoins;\n}\n\nexport interface ProductDmProjectTier {\n product: ProductDetail;\n organisation: OrganisationAllDetail;\n unit: UnitAllDetail;\n storage: ProductDmStorageDetail;\n coins: ProductCoinsDetail;\n instance: ProductInstanceDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n claim?: ProductClaimDetail;\n}\n\nexport interface ProductDmStorage {\n product: ProductDetail;\n organisation: OrganisationAllDetail;\n unit: UnitAllDetail;\n storage: ProductDmStorageDetail;\n coins: ProductCoinsDetail;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n}\n\nexport interface ChargeAdditionalData { [key: string]: unknown }\n\nexport interface StorageChargeItem {\n item_number: number;\n /** The date and time of the processing charge */\n date: string;\n /** The coin-cost of the storage */\n coins: string;\n /** The current burn rate, the approximate amount of coins you are currently consuming each day */\n current_burn_rate?: string;\n /** The date when the charges concluded */\n closed?: string;\n additional_data?: ChargeAdditionalData;\n}\n\nexport interface StorageCharges {\n num_items: number;\n items: StorageChargeItem[];\n}\n\nexport interface ProcessingChargeItem {\n /** The charge record number */\n id: number;\n /** The most recent sequence number for this charge */\n sqn: number;\n name?: string;\n username: string;\n /** The date and time of the processing charge */\n timestamp: string;\n /** The coin-cost of the storage */\n coins: string;\n additional_data?: ChargeAdditionalData;\n}\n\nexport type ProcessingChargesMerchantKind = typeof ProcessingChargesMerchantKind[keyof typeof ProcessingChargesMerchantKind];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProcessingChargesMerchantKind = {\n DATA_MANAGER: 'DATA_MANAGER',\n} as const;\n\nexport interface ProcessingCharges {\n merchant_name: string;\n merchant_kind: ProcessingChargesMerchantKind;\n merchant_api_hostname: string;\n /** The date when the process stopped */\n closed?: string;\n /** True if no further change to the charges can occur. Typically True after the charge has been closed for a pre-configured period of time. */\n final: boolean;\n /** True if charges were received after the charge record was finalised */\n post_final_charges?: boolean;\n charge: ProcessingChargeItem;\n}\n\nexport type AssetDetailScope = typeof AssetDetailScope[keyof typeof AssetDetailScope];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const AssetDetailScope = {\n USER: 'USER',\n PRODUCT: 'PRODUCT',\n UNIT: 'UNIT',\n ORGANISATION: 'ORGANISATION',\n GLOBAL: 'GLOBAL',\n} as const;\n\nexport interface AssetDetail {\n creator: string;\n id: string;\n name: string;\n scope: AssetDetailScope;\n scope_id: string;\n secret: boolean;\n disabled: boolean;\n content: string;\n created: string;\n content_modified?: string;\n description?: string;\n merchants: MerchantDetail[];\n}\n\nexport type UserAccountGetResponse = UserAccountDetail;\n\nexport interface UnitsGetResponse {\n /** A list of Units\n */\n units: OrganisationUnitsGetResponse[];\n}\n\nexport type UnitGetResponse = UnitAllDetail;\n\nexport interface UnitProductPostResponse {\n /** The Product's unique ID */\n id: string;\n}\n\n/**\n * The type of charge\n */\nexport type ChargeSummaryType = typeof ChargeSummaryType[keyof typeof ChargeSummaryType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ChargeSummaryType = {\n PROCESSING: 'PROCESSING',\n STORAGE: 'STORAGE',\n} as const;\n\nexport interface ChargeSummary {\n /** The type of charge */\n type: ChargeSummaryType;\n /** The cost, in coins of the charge */\n coins: string;\n}\n\nexport interface UnitProductChargeSummary {\n product_id: string;\n product_type: string;\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargeSummary {\n charges: ChargeSummary[];\n}\n\nexport interface UnitChargesGetResponse {\n /** Whether the user making the API call is a member of the Unit */\n caller_is_member: boolean;\n unit_id: string;\n name?: string;\n /** The Unit's owner (a username) */\n owner_id: string;\n /** True if the Unit is private */\n private: boolean;\n created: string;\n coins: string;\n count: number;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n summary: UnitChargeSummary;\n products: UnitProductChargeSummary[];\n}\n\n/**\n * The Unit's Product\n */\nexport type ProductUnitGetResponseProduct = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductUnitGetResponse {\n /** The Unit's Product */\n product: ProductUnitGetResponseProduct;\n}\n\nexport interface ProductsGetTypesResponse {\n /** The number of Product Types */\n count: number;\n /** All the Product Types you have access to */\n product_types: ProductType[];\n}\n\nexport type ProductsGetDefaultStorageCostDefaultStorageCost = {\n cost: string;\n units: string;\n description: string;\n};\n\nexport interface ProductsGetDefaultStorageCost {\n default_storage_cost: ProductsGetDefaultStorageCostDefaultStorageCost;\n}\n\nexport type ProductsGetResponseProductsItem = ProductDmStorage | ProductDmProjectTier;\n\nexport interface ProductsGetResponse {\n count: number;\n /** All the Products you have access to */\n products: ProductsGetResponseProductsItem[];\n}\n\nexport type ProductChargesGetResponseProductType = typeof ProductChargesGetResponseProductType[keyof typeof ProductChargesGetResponseProductType];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const ProductChargesGetResponseProductType = {\n DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION: 'DATA_MANAGER_PROJECT_TIER_SUBSCRIPTION',\n DATA_MANAGER_STORAGE_SUBSCRIPTION: 'DATA_MANAGER_STORAGE_SUBSCRIPTION',\n} as const;\n\nexport interface ProductChargesGetResponse {\n product_id: string;\n product_type: ProductChargesGetResponseProductType;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** True if the product can be (needs to be) claimed. */\n claimable: boolean;\n claim?: ProductClaimDetail;\n count: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n /** The total number of coins consumed by this product for the invoice period */\n coins: string;\n processing_charges: ProcessingCharges[];\n storage_charges: StorageCharges;\n}\n\nexport type OrganisationGetResponse = OrganisationAllDetail;\n\nexport interface OrganisationsGetResponse {\n count: number;\n /** A list of Organisations */\n organisations: OrganisationAllDetail[];\n}\n\nexport interface OrganisationUnitChargeSummary {\n unit_id: string;\n name: string;\n /**\n * @minimum 1\n * @maximum 28\n */\n billing_day: number;\n /** The start of the charge period */\n from: string;\n /** The date where of first day after the charge period */\n until: string;\n summary: ChargeSummary[];\n}\n\nexport interface OrganisationChargesGetResponse {\n organisation_id: string;\n name: string;\n coins: string;\n summary: ChargeSummary[];\n unit_charges: OrganisationUnitChargeSummary[];\n}\n\nexport interface OrganisationUnitsGetResponse {\n count?: number;\n organisation: OrganisationAllDetail;\n /** A list of Units\n */\n units: UnitAllDetail[];\n}\n\nexport interface OrganisationChargeSummary {\n organisation_id: string;\n name: string;\n summary: ChargeSummary[];\n}\n\nexport interface PersonalUnitPutResponse {\n /** The unit's Organisation. Used to identify the Default organisation */\n organisation_id: string;\n /** The unit's unique ID */\n id: string;\n}\n\nexport interface OrganisationUnitPostResponse {\n /** The unit's unique ID */\n id: string;\n}\n\n/**\n * The Organisation's default product privacy setting\n */\nexport type OrganisationGetDefaultResponseDefaultProductPrivacy = typeof OrganisationGetDefaultResponseDefaultProductPrivacy[keyof typeof OrganisationGetDefaultResponseDefaultProductPrivacy];\n\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nexport const OrganisationGetDefaultResponseDefaultProductPrivacy = {\n ALWAYS_PUBLIC: 'ALWAYS_PUBLIC',\n ALWAYS_PRIVATE: 'ALWAYS_PRIVATE',\n DEFAULT_PUBLIC: 'DEFAULT_PUBLIC',\n DEFAULT_PRIVATE: 'DEFAULT_PRIVATE',\n} as const;\n\nexport interface OrganisationGetDefaultResponse {\n /** Whether the user making the API call is a member of the Default Organisation. Only admin users are members of the Default organisation */\n caller_is_member?: boolean;\n /** The Default Organisation ID\n */\n id?: string;\n /** The Default Organisation Name\n */\n name?: string;\n /** True if the Organisation is private. The Default organisation is always public, although it does not contain a membership (unless you're admin) and only houses Personal Units\n */\n private?: boolean;\n created?: string;\n /** The Organisation's default product privacy setting */\n default_product_privacy?: OrganisationGetDefaultResponseDefaultProductPrivacy;\n}\n\nexport interface UsersGetResponse {\n count: number;\n organisation?: OrganisationDetail;\n unit?: UnitDetail;\n /** The list of Organisation Users\n */\n users: UserDetail[];\n}\n\nexport interface OrganisationPostResponse {\n /** The Organisation's unique ID */\n id: string;\n}\n\nexport interface StateGetVersionResponse {\n /** The Account Server version. This is guaranteed to be a valid semantic version for official (tagged) images. The version value format for unofficial images is a string but otherwise undefined\n */\n version: string;\n}\n\nexport interface EventStreamGetPostResponse {\n /** The EventStream ID */\n id: number;\n /** The Event Stream location. This will be a URL where events can be fetched. The protocol is typically a WebSocket, but the protocol is defined by the specific Event Stream Service that has been deployed. */\n location: string;\n}\n\nexport interface ChargesGetResponse {\n coins: string;\n count: number;\n summary: ChargeSummary[];\n organisation_charges: OrganisationChargeSummary[];\n}\n\nexport interface AssetPostResponse {\n /** The Asset ID\n */\n id: string;\n}\n\nexport interface AssetGetResponse {\n /** A list of Assets\n */\n assets: AssetDetail[];\n /** The number of Assets returned\n */\n count: number;\n}\n\nexport type AssetGetByIdResponse = AssetDetail;\n\nexport interface AsError {\n /** Brief error text that can be presented to the user */\n error: string;\n}\n\n"],"mappings":";;;;;;;;AA4LO,IAAM,iCAAiC;AAAA,EAC5C,YAAY;AAAA,EACZ,QAAQ;AAAA,EACR,QAAQ;AAAA,EACR,MAAM;AACR;AAWO,IAAM,8BAA8B;AAAA,EACzC,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AAmCO,IAAM,yCAAyC;AAAA,EACpD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAoBO,IAAM,iDAAiD;AAAA,EAC5D,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAkBO,IAAM,oDAAoD;AAAA,EAC/D,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAkCO,IAAM,gDAAgD;AAAA,EAC3D,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAkBO,IAAM,yBAAyB;AAAA,EACpC,MAAM;AAAA,EACN,SAAS;AAAA,EACT,MAAM;AAAA,EACN,cAAc;AAAA,EACd,QAAQ;AACV;AAmDO,IAAM,kCAAkC;AAAA,EAC7C,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AA2BO,IAAM,qCAAqC;AAAA,EAChD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AA6BO,IAAM,qBAAqB;AAAA,EAChC,cAAc;AAChB;AA8BO,IAAM,0CAA0C;AAAA,EACrD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAyBO,IAAM,6CAA6C;AAAA,EACxD,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AA2BO,IAAM,yBAAyB;AAAA,EACpC,cAAc;AAChB;AA6BO,IAAM,uBAAuB;AAAA,EAClC,YAAY;AAAA,EACZ,QAAQ;AAAA,EACR,QAAQ;AAAA,EACR,MAAM;AACR;AAUO,IAAM,oBAAoB;AAAA,EAC/B,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AAuIO,IAAM,gCAAgC;AAAA,EAC3C,cAAc;AAChB;AAmBO,IAAM,mBAAmB;AAAA,EAC9B,MAAM;AAAA,EACN,SAAS;AAAA,EACT,MAAM;AAAA,EACN,cAAc;AAAA,EACd,QAAQ;AACV;AAuCO,IAAM,oBAAoB;AAAA,EAC/B,YAAY;AAAA,EACZ,SAAS;AACX;AAmFO,IAAM,uCAAuC;AAAA,EAClD,wCAAwC;AAAA,EACxC,mCAAmC;AACrC;AAwFO,IAAM,sDAAsD;AAAA,EACjE,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;","names":[]}
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "4.2.0-alpha.8",
2
+ "version": "4.2.0-beta.1",
3
3
  "author": "Oliver Dudgeon",
4
4
  "name": "@squonk/account-server-client",
5
5
  "private": false,
@@ -1041,7 +1041,7 @@ export interface StateGetVersionResponse {
1041
1041
  export interface EventStreamGetPostResponse {
1042
1042
  /** The EventStream ID */
1043
1043
  id: number;
1044
- /** The EventStream location, a URL where events can be fetched. Typically a WebSocket. */
1044
+ /** The Event Stream location. This will be a URL where events can be fetched. The protocol is typically a WebSocket, but the protocol is defined by the specific Event Stream Service that has been deployed. */
1045
1045
  location: string;
1046
1046
  }
1047
1047
 
@@ -41,9 +41,9 @@ type SecondParameter<T extends (...args: any) => any> = Parameters<T>[1];
41
41
 
42
42
 
43
43
  /**
44
- * Gets your EventStream ID and read token, if you have created one.
44
+ * Gets the details of your event stream, if you have created one. The response includes the event stream ID and the **location** where events can be accessed.
45
45
 
46
- * @summary Gets the details of your EventStream
46
+ * @summary Gets the details of your event stream
47
47
  */
48
48
  export const getEventStream = (
49
49
 
@@ -110,7 +110,7 @@ export function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStre
110
110
 
111
111
  ): UseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }
112
112
  /**
113
- * @summary Gets the details of your EventStream
113
+ * @summary Gets the details of your event stream
114
114
  */
115
115
 
116
116
  export function useGetEventStream<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(
@@ -164,7 +164,7 @@ export function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getE
164
164
 
165
165
  ): UseSuspenseQueryResult<TData, TError> & { queryKey: DataTag<QueryKey, TData, TError> }
166
166
  /**
167
- * @summary Gets the details of your EventStream
167
+ * @summary Gets the details of your event stream
168
168
  */
169
169
 
170
170
  export function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getEventStream>>, TError = ErrorType<void | AsError>>(
@@ -184,11 +184,15 @@ export function useGetEventStreamSuspense<TData = Awaited<ReturnType<typeof getE
184
184
 
185
185
 
186
186
  /**
187
- * Creates a new event stream for the authenticated user.
187
+ * Creates a new event stream for the authenticated user. The event Stream delivers near-real-time events to the user where the implementation is dependent on the Event Stream Service that has been installed. Our **Python FastAPI WebSocket** service is one such service.
188
+
189
+ The response will include the event stream ID and the **location** where events can be accessed.
190
+
191
+ The event streaming service is an optional component of the Account Server. If a service is not installed you will receive a corresponding **404** response.
188
192
 
189
193
  A user is only permitted one event stream.
190
194
 
191
- * @summary Create a new Server-Sent Events EventStream
195
+ * @summary Create a new event stream
192
196
  */
193
197
  export const createEventStream = (
194
198
 
@@ -233,7 +237,7 @@ const {mutation: mutationOptions, request: requestOptions} = options ?
233
237
  export type CreateEventStreamMutationError = ErrorType<AsError | void>
234
238
 
235
239
  /**
236
- * @summary Create a new Server-Sent Events EventStream
240
+ * @summary Create a new event stream
237
241
  */
238
242
  export const useCreateEventStream = <TData = Awaited<ReturnType<typeof createEventStream>>, TError = ErrorType<AsError | void>,
239
243
  TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,void, TContext>, request?: SecondParameter<typeof customInstance>}
@@ -249,11 +253,9 @@ export const useCreateEventStream = <TData = Awaited<ReturnType<typeof createEve
249
253
  return useMutation(mutationOptions);
250
254
  }
251
255
  /**
252
- * Deletes an Event Stream.
253
-
254
- You must be the user who created the event stream.
256
+ * You must be the user who created the event stream.
255
257
 
256
- * @summary Deletes an existing EventStream (that you created)
258
+ * @summary Deletes an existing event stream (that you created)
257
259
  */
258
260
  export const deleteEventStream = (
259
261
  eventStreamId: number,
@@ -297,7 +299,7 @@ const {mutation: mutationOptions, request: requestOptions} = options ?
297
299
  export type DeleteEventStreamMutationError = ErrorType<void | AsError>
298
300
 
299
301
  /**
300
- * @summary Deletes an existing EventStream (that you created)
302
+ * @summary Deletes an existing event stream (that you created)
301
303
  */
302
304
  export const useDeleteEventStream = <TData = Awaited<ReturnType<typeof deleteEventStream>>, TError = ErrorType<void | AsError>,
303
305
  TContext = unknown>(options?: { mutation?:UseMutationOptions<TData, TError,{eventStreamId: number}, TContext>, request?: SecondParameter<typeof customInstance>}