File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,12 @@ import type { ApiRequestOptions } from './ApiRequestOptions';
5
5
type Resolver<T > = (options: ApiRequestOptions) => Promise<T >;
6
6
type Headers = Record<string , string>;
7
7
8
+ export type ApiCacheOptions = {
9
+ enabled: boolean;
10
+ ttl?: number;
11
+ key?: string;
12
+ };
13
+
8
14
export type OpenAPIConfig = {
9
15
BASE: string;
10
16
VERSION: string;
@@ -15,7 +21,7 @@ export type OpenAPIConfig = {
15
21
PASSWORD?: string | Resolver<string > | undefined;
16
22
HEADERS?: Headers | Resolver<Headers > | undefined;
17
23
ENCODE_PATH?: ((path: string) => string) | undefined;
18
- CACHE_OPTIONS?: Record< string , any> | undefined;
24
+ CACHE_OPTIONS?: ApiCacheOptions | undefined;
19
25
};
20
26
21
27
export const OpenAPI: OpenAPIConfig = {
You can’t perform that action at this time.
0 commit comments