@ayasofyazilim/saas 0.0.37 → 0.0.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AccountService/AccountServiceClient.ts +65 -65
- package/AccountService/index.ts +8 -8
- package/AccountService/schemas.gen.ts +5103 -5103
- package/AccountService/services.gen.ts +1452 -1452
- package/AccountService/types.gen.ts +9896 -9896
- package/AdministrationService/AdministrationServiceClient.ts +74 -74
- package/AdministrationService/index.ts +8 -8
- package/AdministrationService/schemas.gen.ts +5897 -5897
- package/AdministrationService/services.gen.ts +1332 -1332
- package/AdministrationService/types.gen.ts +9024 -9024
- package/BackerService/index.ts +8 -8
- package/BackerService/schemas.gen.ts +12444 -12444
- package/BackerService/services.gen.ts +866 -866
- package/CRMService/CRMServiceClient.ts +71 -71
- package/CRMService/core/ApiError.ts +20 -20
- package/CRMService/core/ApiRequestOptions.ts +12 -12
- package/CRMService/core/ApiResult.ts +6 -6
- package/CRMService/core/BaseHttpRequest.ts +9 -9
- package/CRMService/core/CancelablePromise.ts +125 -125
- package/CRMService/core/FetchHttpRequest.ts +21 -21
- package/CRMService/core/OpenAPI.ts +55 -55
- package/CRMService/core/request.ts +340 -340
- package/CRMService/index.ts +8 -8
- package/CRMService/schemas.gen.ts +15920 -15920
- package/CRMService/services.gen.ts +2052 -2052
- package/CRMService/types.gen.ts +4106 -4106
- package/ContractService/ContractServiceClient.ts +53 -53
- package/ContractService/core/ApiError.ts +20 -20
- package/ContractService/core/ApiRequestOptions.ts +12 -12
- package/ContractService/core/ApiResult.ts +6 -6
- package/ContractService/core/BaseHttpRequest.ts +9 -9
- package/ContractService/core/CancelablePromise.ts +125 -125
- package/ContractService/core/FetchHttpRequest.ts +21 -21
- package/ContractService/core/OpenAPI.ts +55 -55
- package/ContractService/core/request.ts +340 -340
- package/ContractService/index.ts +8 -8
- package/ContractService/schemas.gen.ts +10943 -10943
- package/ContractService/services.gen.ts +1720 -1720
- package/ContractService/types.gen.ts +3691 -3691
- package/FundraiserService/FundraiserServiceClient.ts +47 -47
- package/FundraiserService/core/ApiError.ts +20 -20
- package/FundraiserService/core/ApiRequestOptions.ts +12 -12
- package/FundraiserService/core/ApiResult.ts +6 -6
- package/FundraiserService/core/BaseHttpRequest.ts +9 -9
- package/FundraiserService/core/CancelablePromise.ts +125 -125
- package/FundraiserService/core/FetchHttpRequest.ts +21 -21
- package/FundraiserService/core/OpenAPI.ts +55 -55
- package/FundraiserService/core/request.ts +340 -340
- package/FundraiserService/schemas.gen.ts +11548 -11548
- package/IdentityService/IdentityServiceClient.ts +77 -77
- package/IdentityService/index.ts +8 -8
- package/IdentityService/schemas.gen.ts +6573 -6573
- package/IdentityService/services.gen.ts +2839 -2839
- package/IdentityService/types.gen.ts +17446 -17446
- package/ProjectService/index.ts +8 -8
- package/ProjectService/schemas.gen.ts +5147 -5147
- package/SaasService/index.ts +8 -8
- package/SaasService/schemas.gen.ts +5278 -5278
- package/SaasService/services.gen.ts +1325 -1325
- package/SaasService/types.gen.ts +9052 -9052
- package/SettingService/SettingServiceClient.ts +62 -62
- package/SettingService/index.ts +8 -8
- package/TravellerService/TravellerServiceClient.ts +56 -56
- package/TravellerService/core/ApiError.ts +20 -20
- package/TravellerService/core/ApiRequestOptions.ts +12 -12
- package/TravellerService/core/ApiResult.ts +6 -6
- package/TravellerService/core/BaseHttpRequest.ts +9 -9
- package/TravellerService/core/CancelablePromise.ts +125 -125
- package/TravellerService/core/FetchHttpRequest.ts +21 -21
- package/TravellerService/core/OpenAPI.ts +55 -55
- package/TravellerService/core/request.ts +340 -340
- package/TravellerService/index.ts +8 -8
- package/TravellerService/schemas.gen.ts +6204 -7980
- package/TravellerService/services.gen.ts +695 -709
- package/TravellerService/types.gen.ts +1808 -1850
- package/generator.mjs +4 -8
- package/package.json +1 -1
|
@@ -1,56 +1,56 @@
|
|
|
1
|
-
import type { ApiRequestOptions } from './ApiRequestOptions';
|
|
2
|
-
|
|
3
|
-
type Headers = Record<string, string>;
|
|
4
|
-
type Middleware<T> = (value: T) => T | Promise<T>;
|
|
5
|
-
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>;
|
|
6
|
-
|
|
7
|
-
export class Interceptors<T> {
|
|
8
|
-
_fns: Middleware<T>[];
|
|
9
|
-
|
|
10
|
-
constructor() {
|
|
11
|
-
this._fns = [];
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
eject(fn: Middleware<T>) {
|
|
15
|
-
const index = this._fns.indexOf(fn);
|
|
16
|
-
if (index !== -1) {
|
|
17
|
-
this._fns = [...this._fns.slice(0, index), ...this._fns.slice(index + 1)];
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
use(fn: Middleware<T>) {
|
|
22
|
-
this._fns = [...this._fns, fn];
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
export type OpenAPIConfig = {
|
|
27
|
-
BASE: string;
|
|
28
|
-
CREDENTIALS: 'include' | 'omit' | 'same-origin';
|
|
29
|
-
ENCODE_PATH?: ((path: string) => string) | undefined;
|
|
30
|
-
HEADERS?: Headers | Resolver<Headers> | undefined;
|
|
31
|
-
PASSWORD?: string | Resolver<string> | undefined;
|
|
32
|
-
TOKEN?: string | Resolver<string> | undefined;
|
|
33
|
-
USERNAME?: string | Resolver<string> | undefined;
|
|
34
|
-
VERSION: string;
|
|
35
|
-
WITH_CREDENTIALS: boolean;
|
|
36
|
-
interceptors: {
|
|
37
|
-
request: Interceptors<RequestInit>;
|
|
38
|
-
response: Interceptors<Response>;
|
|
39
|
-
};
|
|
40
|
-
};
|
|
41
|
-
|
|
42
|
-
export const OpenAPI: OpenAPIConfig = {
|
|
43
|
-
BASE: '',
|
|
44
|
-
CREDENTIALS: 'include',
|
|
45
|
-
ENCODE_PATH: undefined,
|
|
46
|
-
HEADERS: undefined,
|
|
47
|
-
PASSWORD: undefined,
|
|
48
|
-
TOKEN: undefined,
|
|
49
|
-
USERNAME: undefined,
|
|
50
|
-
VERSION: '1',
|
|
51
|
-
WITH_CREDENTIALS: false,
|
|
52
|
-
interceptors: {
|
|
53
|
-
request: new Interceptors(),
|
|
54
|
-
response: new Interceptors(),
|
|
55
|
-
},
|
|
1
|
+
import type { ApiRequestOptions } from './ApiRequestOptions';
|
|
2
|
+
|
|
3
|
+
type Headers = Record<string, string>;
|
|
4
|
+
type Middleware<T> = (value: T) => T | Promise<T>;
|
|
5
|
+
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>;
|
|
6
|
+
|
|
7
|
+
export class Interceptors<T> {
|
|
8
|
+
_fns: Middleware<T>[];
|
|
9
|
+
|
|
10
|
+
constructor() {
|
|
11
|
+
this._fns = [];
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
eject(fn: Middleware<T>) {
|
|
15
|
+
const index = this._fns.indexOf(fn);
|
|
16
|
+
if (index !== -1) {
|
|
17
|
+
this._fns = [...this._fns.slice(0, index), ...this._fns.slice(index + 1)];
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
use(fn: Middleware<T>) {
|
|
22
|
+
this._fns = [...this._fns, fn];
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export type OpenAPIConfig = {
|
|
27
|
+
BASE: string;
|
|
28
|
+
CREDENTIALS: 'include' | 'omit' | 'same-origin';
|
|
29
|
+
ENCODE_PATH?: ((path: string) => string) | undefined;
|
|
30
|
+
HEADERS?: Headers | Resolver<Headers> | undefined;
|
|
31
|
+
PASSWORD?: string | Resolver<string> | undefined;
|
|
32
|
+
TOKEN?: string | Resolver<string> | undefined;
|
|
33
|
+
USERNAME?: string | Resolver<string> | undefined;
|
|
34
|
+
VERSION: string;
|
|
35
|
+
WITH_CREDENTIALS: boolean;
|
|
36
|
+
interceptors: {
|
|
37
|
+
request: Interceptors<RequestInit>;
|
|
38
|
+
response: Interceptors<Response>;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
|
|
42
|
+
export const OpenAPI: OpenAPIConfig = {
|
|
43
|
+
BASE: '',
|
|
44
|
+
CREDENTIALS: 'include',
|
|
45
|
+
ENCODE_PATH: undefined,
|
|
46
|
+
HEADERS: undefined,
|
|
47
|
+
PASSWORD: undefined,
|
|
48
|
+
TOKEN: undefined,
|
|
49
|
+
USERNAME: undefined,
|
|
50
|
+
VERSION: '1',
|
|
51
|
+
WITH_CREDENTIALS: false,
|
|
52
|
+
interceptors: {
|
|
53
|
+
request: new Interceptors(),
|
|
54
|
+
response: new Interceptors(),
|
|
55
|
+
},
|
|
56
56
|
};
|