···11+// This file is auto-generated by @hey-api/openapi-ts
22+33+import { type ClientOptions, type Config, createClient, createConfig } from './client';
44+import type { ClientOptions as ClientOptions2 } from './types.gen';
55+66+/**
77+ * The `createClientConfig()` function will be called on client initialization
88+ * and the returned object will become the client's initial configuration.
99+ *
1010+ * You may want to initialize your client this way instead of calling
1111+ * `setConfig()`. This is useful for example if you're using Next.js
1212+ * to ensure your client always has the correct values.
1313+ */
1414+export type CreateClientConfig<T extends ClientOptions = ClientOptions2> = (override?: Config<ClientOptions & T>) => Config<Required<ClientOptions> & T>;
1515+1616+export const client = createClient(createConfig<ClientOptions2>({ baseUrl: 'http://localhost:3000/base' }));
···11+// This file is auto-generated by @hey-api/openapi-ts
22+33+import type { Auth, AuthToken } from './auth.gen';
44+import type { BodySerializer, QuerySerializer, QuerySerializerOptions } from './bodySerializer.gen';
55+66+export type HttpMethod =
77+ | 'connect'
88+ | 'delete'
99+ | 'get'
1010+ | 'head'
1111+ | 'options'
1212+ | 'patch'
1313+ | 'post'
1414+ | 'put'
1515+ | 'trace';
1616+1717+export type Client<
1818+ RequestFn = never,
1919+ Config = unknown,
2020+ MethodFn = never,
2121+ BuildUrlFn = never,
2222+ SseFn = never,
2323+> = {
2424+ /**
2525+ * Returns the final request URL.
2626+ */
2727+ buildUrl: BuildUrlFn;
2828+ getConfig: () => Config;
2929+ request: RequestFn;
3030+ setConfig: (config: Config) => Config;
3131+} & {
3232+ [K in HttpMethod]: MethodFn;
3333+} & ([SseFn] extends [never] ? { sse?: never } : { sse: { [K in HttpMethod]: SseFn } });
3434+3535+export interface Config {
3636+ /**
3737+ * Auth token or a function returning auth token. The resolved value will be
3838+ * added to the request payload as defined by its `security` array.
3939+ */
4040+ auth?: ((auth: Auth) => Promise<AuthToken> | AuthToken) | AuthToken;
4141+ /**
4242+ * A function for serializing request body parameter. By default,
4343+ * {@link JSON.stringify()} will be used.
4444+ */
4545+ bodySerializer?: BodySerializer | null;
4646+ /**
4747+ * An object containing any HTTP headers that you want to pre-populate your
4848+ * `Headers` object with.
4949+ *
5050+ * {@link https://developer.mozilla.org/docs/Web/API/Headers/Headers#init See more}
5151+ */
5252+ headers?:
5353+ | RequestInit['headers']
5454+ | Record<
5555+ string,
5656+ string | number | boolean | (string | number | boolean)[] | null | undefined | unknown
5757+ >;
5858+ /**
5959+ * The request method.
6060+ *
6161+ * {@link https://developer.mozilla.org/docs/Web/API/fetch#method See more}
6262+ */
6363+ method?: Uppercase<HttpMethod>;
6464+ /**
6565+ * A function for serializing request query parameters. By default, arrays
6666+ * will be exploded in form style, objects will be exploded in deepObject
6767+ * style, and reserved characters are percent-encoded.
6868+ *
6969+ * This method will have no effect if the native `paramsSerializer()` Axios
7070+ * API function is used.
7171+ *
7272+ * {@link https://swagger.io/docs/specification/serialization/#query View examples}
7373+ */
7474+ querySerializer?: QuerySerializer | QuerySerializerOptions;
7575+ /**
7676+ * A function validating request data. This is useful if you want to ensure
7777+ * the request conforms to the desired shape, so it can be safely sent to
7878+ * the server.
7979+ */
8080+ requestValidator?: (data: unknown) => Promise<unknown>;
8181+ /**
8282+ * A function transforming response data before it's returned. This is useful
8383+ * for post-processing data, e.g. converting ISO strings into Date objects.
8484+ */
8585+ responseTransformer?: (data: unknown) => Promise<unknown>;
8686+ /**
8787+ * A function validating response data. This is useful if you want to ensure
8888+ * the response conforms to the desired shape, so it can be safely passed to
8989+ * the transformers and returned to the user.
9090+ */
9191+ responseValidator?: (data: unknown) => Promise<unknown>;
9292+}
9393+9494+type IsExactlyNeverOrNeverUndefined<T> = [T] extends [never]
9595+ ? true
9696+ : [T] extends [never | undefined]
9797+ ? [undefined] extends [T]
9898+ ? false
9999+ : true
100100+ : false;
101101+102102+export type OmitNever<T extends Record<string, unknown>> = {
103103+ [K in keyof T as IsExactlyNeverOrNeverUndefined<T[K]> extends true ? never : K]: T[K];
104104+};
···11+// This file is auto-generated by @hey-api/openapi-ts
22+33+import { type ClientOptions, type Config, createClient, createConfig } from './client';
44+import type { ClientOptions as ClientOptions2 } from './types.gen';
55+66+/**
77+ * The `createClientConfig()` function will be called on client initialization
88+ * and the returned object will become the client's initial configuration.
99+ *
1010+ * You may want to initialize your client this way instead of calling
1111+ * `setConfig()`. This is useful for example if you're using Next.js
1212+ * to ensure your client always has the correct values.
1313+ */
1414+export type CreateClientConfig<T extends ClientOptions = ClientOptions2> = (override?: Config<ClientOptions & T>) => Config<Required<ClientOptions> & T>;
1515+1616+export const client = createClient(createConfig<ClientOptions2>({ baseUrl: 'http://localhost:3000/base' }));
···11+// This file is auto-generated by @hey-api/openapi-ts
22+33+import type { Auth, AuthToken } from './auth.gen';
44+import type { BodySerializer, QuerySerializer, QuerySerializerOptions } from './bodySerializer.gen';
55+66+export type HttpMethod =
77+ | 'connect'
88+ | 'delete'
99+ | 'get'
1010+ | 'head'
1111+ | 'options'
1212+ | 'patch'
1313+ | 'post'
1414+ | 'put'
1515+ | 'trace';
1616+1717+export type Client<
1818+ RequestFn = never,
1919+ Config = unknown,
2020+ MethodFn = never,
2121+ BuildUrlFn = never,
2222+ SseFn = never,
2323+> = {
2424+ /**
2525+ * Returns the final request URL.
2626+ */
2727+ buildUrl: BuildUrlFn;
2828+ getConfig: () => Config;
2929+ request: RequestFn;
3030+ setConfig: (config: Config) => Config;
3131+} & {
3232+ [K in HttpMethod]: MethodFn;
3333+} & ([SseFn] extends [never] ? { sse?: never } : { sse: { [K in HttpMethod]: SseFn } });
3434+3535+export interface Config {
3636+ /**
3737+ * Auth token or a function returning auth token. The resolved value will be
3838+ * added to the request payload as defined by its `security` array.
3939+ */
4040+ auth?: ((auth: Auth) => Promise<AuthToken> | AuthToken) | AuthToken;
4141+ /**
4242+ * A function for serializing request body parameter. By default,
4343+ * {@link JSON.stringify()} will be used.
4444+ */
4545+ bodySerializer?: BodySerializer | null;
4646+ /**
4747+ * An object containing any HTTP headers that you want to pre-populate your
4848+ * `Headers` object with.
4949+ *
5050+ * {@link https://developer.mozilla.org/docs/Web/API/Headers/Headers#init See more}
5151+ */
5252+ headers?:
5353+ | RequestInit['headers']
5454+ | Record<
5555+ string,
5656+ string | number | boolean | (string | number | boolean)[] | null | undefined | unknown
5757+ >;
5858+ /**
5959+ * The request method.
6060+ *
6161+ * {@link https://developer.mozilla.org/docs/Web/API/fetch#method See more}
6262+ */
6363+ method?: Uppercase<HttpMethod>;
6464+ /**
6565+ * A function for serializing request query parameters. By default, arrays
6666+ * will be exploded in form style, objects will be exploded in deepObject
6767+ * style, and reserved characters are percent-encoded.
6868+ *
6969+ * This method will have no effect if the native `paramsSerializer()` Axios
7070+ * API function is used.
7171+ *
7272+ * {@link https://swagger.io/docs/specification/serialization/#query View examples}
7373+ */
7474+ querySerializer?: QuerySerializer | QuerySerializerOptions;
7575+ /**
7676+ * A function validating request data. This is useful if you want to ensure
7777+ * the request conforms to the desired shape, so it can be safely sent to
7878+ * the server.
7979+ */
8080+ requestValidator?: (data: unknown) => Promise<unknown>;
8181+ /**
8282+ * A function transforming response data before it's returned. This is useful
8383+ * for post-processing data, e.g. converting ISO strings into Date objects.
8484+ */
8585+ responseTransformer?: (data: unknown) => Promise<unknown>;
8686+ /**
8787+ * A function validating response data. This is useful if you want to ensure
8888+ * the response conforms to the desired shape, so it can be safely passed to
8989+ * the transformers and returned to the user.
9090+ */
9191+ responseValidator?: (data: unknown) => Promise<unknown>;
9292+}
9393+9494+type IsExactlyNeverOrNeverUndefined<T> = [T] extends [never]
9595+ ? true
9696+ : [T] extends [never | undefined]
9797+ ? [undefined] extends [T]
9898+ ? false
9999+ : true
100100+ : false;
101101+102102+export type OmitNever<T extends Record<string, unknown>> = {
103103+ [K in keyof T as IsExactlyNeverOrNeverUndefined<T[K]> extends true ? never : K]: T[K];
104104+};
···11+// This file is auto-generated by @hey-api/openapi-ts
22+33+import { type ClientOptions, type Config, createClient, createConfig } from './client';
44+import type { ClientOptions as ClientOptions2 } from './types.gen';
55+66+/**
77+ * The `createClientConfig()` function will be called on client initialization
88+ * and the returned object will become the client's initial configuration.
99+ *
1010+ * You may want to initialize your client this way instead of calling
1111+ * `setConfig()`. This is useful for example if you're using Next.js
1212+ * to ensure your client always has the correct values.
1313+ */
1414+export type CreateClientConfig<T extends ClientOptions = ClientOptions2> = (override?: Config<ClientOptions & T>) => Config<Required<ClientOptions> & T>;
1515+1616+export const client = createClient(createConfig<ClientOptions2>({ baseUrl: 'http://localhost:3000/base' }));
···11+// This file is auto-generated by @hey-api/openapi-ts
22+33+import type { Auth, AuthToken } from './auth.gen';
44+import type { BodySerializer, QuerySerializer, QuerySerializerOptions } from './bodySerializer.gen';
55+66+export type HttpMethod =
77+ | 'connect'
88+ | 'delete'
99+ | 'get'
1010+ | 'head'
1111+ | 'options'
1212+ | 'patch'
1313+ | 'post'
1414+ | 'put'
1515+ | 'trace';
1616+1717+export type Client<
1818+ RequestFn = never,
1919+ Config = unknown,
2020+ MethodFn = never,
2121+ BuildUrlFn = never,
2222+ SseFn = never,
2323+> = {
2424+ /**
2525+ * Returns the final request URL.
2626+ */
2727+ buildUrl: BuildUrlFn;
2828+ getConfig: () => Config;
2929+ request: RequestFn;
3030+ setConfig: (config: Config) => Config;
3131+} & {
3232+ [K in HttpMethod]: MethodFn;
3333+} & ([SseFn] extends [never] ? { sse?: never } : { sse: { [K in HttpMethod]: SseFn } });
3434+3535+export interface Config {
3636+ /**
3737+ * Auth token or a function returning auth token. The resolved value will be
3838+ * added to the request payload as defined by its `security` array.
3939+ */
4040+ auth?: ((auth: Auth) => Promise<AuthToken> | AuthToken) | AuthToken;
4141+ /**
4242+ * A function for serializing request body parameter. By default,
4343+ * {@link JSON.stringify()} will be used.
4444+ */
4545+ bodySerializer?: BodySerializer | null;
4646+ /**
4747+ * An object containing any HTTP headers that you want to pre-populate your
4848+ * `Headers` object with.
4949+ *
5050+ * {@link https://developer.mozilla.org/docs/Web/API/Headers/Headers#init See more}
5151+ */
5252+ headers?:
5353+ | RequestInit['headers']
5454+ | Record<
5555+ string,
5656+ string | number | boolean | (string | number | boolean)[] | null | undefined | unknown
5757+ >;
5858+ /**
5959+ * The request method.
6060+ *
6161+ * {@link https://developer.mozilla.org/docs/Web/API/fetch#method See more}
6262+ */
6363+ method?: Uppercase<HttpMethod>;
6464+ /**
6565+ * A function for serializing request query parameters. By default, arrays
6666+ * will be exploded in form style, objects will be exploded in deepObject
6767+ * style, and reserved characters are percent-encoded.
6868+ *
6969+ * This method will have no effect if the native `paramsSerializer()` Axios
7070+ * API function is used.
7171+ *
7272+ * {@link https://swagger.io/docs/specification/serialization/#query View examples}
7373+ */
7474+ querySerializer?: QuerySerializer | QuerySerializerOptions;
7575+ /**
7676+ * A function validating request data. This is useful if you want to ensure
7777+ * the request conforms to the desired shape, so it can be safely sent to
7878+ * the server.
7979+ */
8080+ requestValidator?: (data: unknown) => Promise<unknown>;
8181+ /**
8282+ * A function transforming response data before it's returned. This is useful
8383+ * for post-processing data, e.g. converting ISO strings into Date objects.
8484+ */
8585+ responseTransformer?: (data: unknown) => Promise<unknown>;
8686+ /**
8787+ * A function validating response data. This is useful if you want to ensure
8888+ * the response conforms to the desired shape, so it can be safely passed to
8989+ * the transformers and returned to the user.
9090+ */
9191+ responseValidator?: (data: unknown) => Promise<unknown>;
9292+}
9393+9494+type IsExactlyNeverOrNeverUndefined<T> = [T] extends [never]
9595+ ? true
9696+ : [T] extends [never | undefined]
9797+ ? [undefined] extends [T]
9898+ ? false
9999+ : true
100100+ : false;
101101+102102+export type OmitNever<T extends Record<string, unknown>> = {
103103+ [K in keyof T as IsExactlyNeverOrNeverUndefined<T[K]> extends true ? never : K]: T[K];
104104+};
···142142 */
143143 enabled?: boolean;
144144 /**
145145+ * Whether to export generated symbols.
146146+ *
147147+ * @default true
148148+ */
149149+ exported?: boolean;
150150+ /**
145151 * Custom function to generate metadata for the operation.
146152 * Can return any valid meta object that will be included in the generated mutation options.
147153 * @param operation - The operation object containing all available metadata
···340346 */
341347 mutationOptions: NamingOptions &
342348 FeatureToggle & {
349349+ /**
350350+ * Whether to export generated symbols.
351351+ *
352352+ * @default true
353353+ */
354354+ exported: boolean;
343355 /**
344356 * Custom function to generate metadata for the operation.
345357 * Can return any valid meta object that will be included in the generated mutation options.
···149149 */
150150 enabled?: boolean;
151151 /**
152152+ * Whether to export generated symbols.
153153+ *
154154+ * @default true
155155+ */
156156+ exported?: boolean;
157157+ /**
152158 * Custom function to generate metadata for the operation.
153159 * Can return any valid meta object that will be included in the generated mutation options.
154160 * @param operation - The operation object containing all available metadata
···347353 */
348354 mutationOptions: NamingOptions &
349355 FeatureToggle & {
356356+ /**
357357+ * Whether to export generated symbols.
358358+ *
359359+ * @default true
360360+ */
361361+ exported: boolean;
350362 /**
351363 * Custom function to generate metadata for the operation.
352364 * Can return any valid meta object that will be included in the generated mutation options.
···148148 */
149149 enabled?: boolean;
150150 /**
151151+ * Whether to export generated symbols.
152152+ *
153153+ * @default true
154154+ */
155155+ exported?: boolean;
156156+ /**
151157 * Custom function to generate metadata for the operation.
152158 * Can return any valid meta object that will be included in the generated mutation options.
153159 * @param operation - The operation object containing all available metadata
···346352 */
347353 mutationOptions: NamingOptions &
348354 FeatureToggle & {
355355+ /**
356356+ * Whether to export generated symbols.
357357+ *
358358+ * @default true
359359+ */
360360+ exported: boolean;
349361 /**
350362 * Custom function to generate metadata for the operation.
351363 * Can return any valid meta object that will be included in the generated mutation options.
···149149 */
150150 enabled?: boolean;
151151 /**
152152+ * Whether to export generated symbols.
153153+ *
154154+ * @default true
155155+ */
156156+ exported?: boolean;
157157+ /**
152158 * Custom function to generate metadata for the operation.
153159 * Can return any valid meta object that will be included in the generated mutation options.
154160 *
···350356 */
351357 mutationOptions: NamingOptions &
352358 FeatureToggle & {
359359+ /**
360360+ * Whether to export generated symbols.
361361+ *
362362+ * @default true
363363+ */
364364+ exported: boolean;
353365 /**
354366 * Custom function to generate metadata for the operation.
355367 * Can return any valid meta object that will be included in the generated mutation options.