@nestia/fetcher 11.0.0-dev.20260312 → 11.0.0-dev.20260313
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/package.json +3 -3
- package/src/EncryptedFetcher.ts +176 -176
- package/src/FormDataInput.ts +80 -80
- package/src/IConnection.ts +241 -241
- package/src/IEncryptionPassword.ts +44 -44
- package/src/IFetchEvent.ts +31 -31
- package/src/IFetchRoute.ts +60 -60
- package/src/IPropagation.ts +99 -99
- package/src/NestiaSimulator.ts +82 -82
- package/src/PlainFetcher.ts +105 -105
- package/src/internal/FetcherBase.ts +235 -235
- package/lib/AesPkcs5.d.ts +0 -30
- package/lib/AesPkcs5.js +0 -49
- package/lib/AesPkcs5.js.map +0 -1
- package/lib/EncryptedFetcher.d.ts +0 -47
- package/lib/EncryptedFetcher.js +0 -98
- package/lib/EncryptedFetcher.js.map +0 -1
- package/lib/FormDataInput.d.ts +0 -70
- package/lib/FormDataInput.js +0 -3
- package/lib/FormDataInput.js.map +0 -1
- package/lib/HttpError.d.ts +0 -1
- package/lib/HttpError.js +0 -6
- package/lib/HttpError.js.map +0 -1
- package/lib/IConnection.d.ts +0 -165
- package/lib/IConnection.js +0 -3
- package/lib/IConnection.js.map +0 -1
- package/lib/IEncryptionPassword.d.ts +0 -41
- package/lib/IEncryptionPassword.js +0 -3
- package/lib/IEncryptionPassword.js.map +0 -1
- package/lib/IFetchEvent.d.ts +0 -11
- package/lib/IFetchEvent.js +0 -21
- package/lib/IFetchEvent.js.map +0 -1
- package/lib/IFetchRoute.d.ts +0 -46
- package/lib/IFetchRoute.js +0 -3
- package/lib/IFetchRoute.js.map +0 -1
- package/lib/IPropagation.d.ts +0 -69
- package/lib/IPropagation.js +0 -3
- package/lib/IPropagation.js.map +0 -1
- package/lib/NestiaSimulator.d.ts +0 -13
- package/lib/NestiaSimulator.js +0 -44
- package/lib/NestiaSimulator.js.map +0 -1
- package/lib/PlainFetcher.d.ts +0 -46
- package/lib/PlainFetcher.js +0 -58
- package/lib/PlainFetcher.js.map +0 -1
- package/lib/index.d.ts +0 -11
- package/lib/index.js +0 -28
- package/lib/index.js.map +0 -1
- package/lib/internal/FetcherBase.d.ts +0 -1
- package/lib/internal/FetcherBase.js +0 -185
- package/lib/internal/FetcherBase.js.map +0 -1
package/lib/EncryptedFetcher.js
DELETED
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.EncryptedFetcher = void 0;
|
|
13
|
-
const AesPkcs5_1 = require("./AesPkcs5");
|
|
14
|
-
const FetcherBase_1 = require("./internal/FetcherBase");
|
|
15
|
-
/**
|
|
16
|
-
* Utility class for `fetch` functions used in `@nestia/sdk` with encryption.
|
|
17
|
-
*
|
|
18
|
-
* `EncryptedFetcher` is a utility class designed for SDK functions generated by
|
|
19
|
-
* [`@nestia/sdk`](https://nestia.io/docs/sdk/sdk), interacting with the remote
|
|
20
|
-
* HTTP API encrypted by AES-PKCS algorithm. In other words, this is a
|
|
21
|
-
* collection of dedicated `fetch()` functions for `@nestia/sdk` with
|
|
22
|
-
* encryption.
|
|
23
|
-
*
|
|
24
|
-
* For reference, `EncryptedFetcher` class being used only when target
|
|
25
|
-
* controller method is encrypting body data by `@EncryptedRoute` or
|
|
26
|
-
* `@EncryptedBody` decorators. If those decorators are not used,
|
|
27
|
-
* {@link PlainFetcher} class would be used instead.
|
|
28
|
-
*
|
|
29
|
-
* @author Jeongho Nam - https://github.com/samchon
|
|
30
|
-
*/
|
|
31
|
-
var EncryptedFetcher;
|
|
32
|
-
(function (EncryptedFetcher) {
|
|
33
|
-
function fetch(connection, route, input, stringify) {
|
|
34
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
35
|
-
var _a, _b, _c, _d;
|
|
36
|
-
if ((((_a = route.request) === null || _a === void 0 ? void 0 : _a.encrypted) === true || ((_b = route.response) === null || _b === void 0 ? void 0 : _b.encrypted)) &&
|
|
37
|
-
connection.encryption === undefined)
|
|
38
|
-
throw new Error("Error on EncryptedFetcher.fetch(): the encryption password has not been configured.");
|
|
39
|
-
const closure = typeof connection.encryption === "function"
|
|
40
|
-
? (direction) => (headers, body) => connection.encryption({
|
|
41
|
-
headers,
|
|
42
|
-
body,
|
|
43
|
-
direction,
|
|
44
|
-
})
|
|
45
|
-
: () => () => connection.encryption;
|
|
46
|
-
return FetcherBase_1.FetcherBase.request({
|
|
47
|
-
className: "EncryptedFetcher",
|
|
48
|
-
encode: ((_c = route.request) === null || _c === void 0 ? void 0 : _c.encrypted) === true
|
|
49
|
-
? (input, headers) => {
|
|
50
|
-
const p = closure("encode")(headers, input);
|
|
51
|
-
return AesPkcs5_1.AesPkcs5.encrypt((stringify !== null && stringify !== void 0 ? stringify : JSON.stringify)(input), p.key, p.iv);
|
|
52
|
-
}
|
|
53
|
-
: (input) => input,
|
|
54
|
-
decode: ((_d = route.response) === null || _d === void 0 ? void 0 : _d.encrypted) === true
|
|
55
|
-
? (input, headers) => {
|
|
56
|
-
const p = closure("decode")(headers, input);
|
|
57
|
-
const s = AesPkcs5_1.AesPkcs5.decrypt(input, p.key, p.iv);
|
|
58
|
-
return s.length ? JSON.parse(s) : s;
|
|
59
|
-
}
|
|
60
|
-
: (input) => input,
|
|
61
|
-
})(connection, route, input, stringify);
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
EncryptedFetcher.fetch = fetch;
|
|
65
|
-
function propagate(connection, route, input, stringify) {
|
|
66
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
67
|
-
var _a, _b, _c, _d;
|
|
68
|
-
if ((((_a = route.request) === null || _a === void 0 ? void 0 : _a.encrypted) === true || ((_b = route.response) === null || _b === void 0 ? void 0 : _b.encrypted)) &&
|
|
69
|
-
connection.encryption === undefined)
|
|
70
|
-
throw new Error("Error on EncryptedFetcher.propagate(): the encryption password has not been configured.");
|
|
71
|
-
const closure = typeof connection.encryption === "function"
|
|
72
|
-
? (direction) => (headers, body) => connection.encryption({
|
|
73
|
-
headers,
|
|
74
|
-
body,
|
|
75
|
-
direction,
|
|
76
|
-
})
|
|
77
|
-
: () => () => connection.encryption;
|
|
78
|
-
return FetcherBase_1.FetcherBase.propagate({
|
|
79
|
-
className: "EncryptedFetcher",
|
|
80
|
-
encode: ((_c = route.request) === null || _c === void 0 ? void 0 : _c.encrypted) === true
|
|
81
|
-
? (input, headers) => {
|
|
82
|
-
const p = closure("encode")(headers, input);
|
|
83
|
-
return AesPkcs5_1.AesPkcs5.encrypt((stringify !== null && stringify !== void 0 ? stringify : JSON.stringify)(input), p.key, p.iv);
|
|
84
|
-
}
|
|
85
|
-
: (input) => input,
|
|
86
|
-
decode: ((_d = route.response) === null || _d === void 0 ? void 0 : _d.encrypted) === true
|
|
87
|
-
? (input, headers) => {
|
|
88
|
-
const p = closure("decode")(headers, input);
|
|
89
|
-
const s = AesPkcs5_1.AesPkcs5.decrypt(input, p.key, p.iv);
|
|
90
|
-
return s.length ? JSON.parse(s) : s;
|
|
91
|
-
}
|
|
92
|
-
: (input) => input,
|
|
93
|
-
})(connection, route, input, stringify);
|
|
94
|
-
});
|
|
95
|
-
}
|
|
96
|
-
EncryptedFetcher.propagate = propagate;
|
|
97
|
-
})(EncryptedFetcher || (exports.EncryptedFetcher = EncryptedFetcher = {}));
|
|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CAAC,KAAK;aACvB,CAAC,CAAC,UAAU,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,CAAoB,CAAC;QAC7D,CAAC;KAAA;IAjDqB,0BAAS,YAiD9B,CAAA;AACH,CAAC,EAxJgB,gBAAgB,gCAAhB,gBAAgB,QAwJhC"}
|
package/lib/FormDataInput.d.ts
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* FormData input type.
|
|
3
|
-
*
|
|
4
|
-
* `FormDataInput<T>` is a type for the input of the `FormData` request, casting
|
|
5
|
-
* `File` property value type as an union of `File` and
|
|
6
|
-
* {@link FormDataInput.IFileProps}, especially for the React Native
|
|
7
|
-
* environment.
|
|
8
|
-
*
|
|
9
|
-
* You know what? In the React Native environment, `File` class is not
|
|
10
|
-
* supported. Therefore, when composing a `FormData` request, you have to put
|
|
11
|
-
* the URI address of the local filesystem with file name and content type that
|
|
12
|
-
* is represented by the {@link FormDataInput.IFileProps} type.
|
|
13
|
-
*
|
|
14
|
-
* This `FormDataInput<T>` type is designed for that purpose. If the property
|
|
15
|
-
* value type is a `File` class, it converts it to an union type of `File` and
|
|
16
|
-
* {@link FormDataInput.IFileProps} type. Also, if the property value type is an
|
|
17
|
-
* array of `File` class, it converts it to an array of union type of `File` and
|
|
18
|
-
* {@link FormDataInput.IFileProps} type too.
|
|
19
|
-
*
|
|
20
|
-
* Before | After ----------|------------------------ `boolean` | `boolean`
|
|
21
|
-
* `bigint` | `bigint` `number` | `number` `string` | `string` `File` | `File \|
|
|
22
|
-
* IFileProps`
|
|
23
|
-
*
|
|
24
|
-
* @author Jeongho Nam - https://github.com/samchon
|
|
25
|
-
* @template T Target object type.
|
|
26
|
-
*/
|
|
27
|
-
export type FormDataInput<T extends object> = T extends Array<any> ? never : T extends Function ? never : {
|
|
28
|
-
[P in keyof T]: T[P] extends Array<infer U> ? FormDataInput.Value<U>[] : FormDataInput.Value<T[P]>;
|
|
29
|
-
};
|
|
30
|
-
export declare namespace FormDataInput {
|
|
31
|
-
/**
|
|
32
|
-
* Value type of the `FormDataInput`.
|
|
33
|
-
*
|
|
34
|
-
* `Value<T>` is a type for the property value defined in the `FormDataInput`.
|
|
35
|
-
*
|
|
36
|
-
* If the original value type is a `File` class, `Value<T>` converts it to an
|
|
37
|
-
* union type of `File` and {@link IFileProps} type which is a structured data
|
|
38
|
-
* for the URI file location in the React Native environment.
|
|
39
|
-
*/
|
|
40
|
-
type Value<T> = T extends File ? T | IFileProps : T;
|
|
41
|
-
/**
|
|
42
|
-
* Properties of a file.
|
|
43
|
-
*
|
|
44
|
-
* In the React Native, this `IFileProps` structured data can replace the
|
|
45
|
-
* `File` class instance in the `FormData` request.
|
|
46
|
-
*
|
|
47
|
-
* Just put the {@link uri URI address} of the local file system with the
|
|
48
|
-
* file's {@link name} and {@link type}. It would be casted to the `File` class
|
|
49
|
-
* instance automatically in the `FormData` request.
|
|
50
|
-
*
|
|
51
|
-
* Note that, this `IFileProps` type works only in the React Native
|
|
52
|
-
* environment. If you are developing a Web or NodeJS application, you have to
|
|
53
|
-
* utilize the `File` class instance directly.
|
|
54
|
-
*/
|
|
55
|
-
interface IFileProps {
|
|
56
|
-
/**
|
|
57
|
-
* URI address of the file.
|
|
58
|
-
*
|
|
59
|
-
* In the React Native, the URI address in the local file system can replace
|
|
60
|
-
* the `File` class instance. If
|
|
61
|
-
*
|
|
62
|
-
* @format uri
|
|
63
|
-
*/
|
|
64
|
-
uri: string;
|
|
65
|
-
/** Name of the file. */
|
|
66
|
-
name: string;
|
|
67
|
-
/** Content type of the file. */
|
|
68
|
-
type: string;
|
|
69
|
-
}
|
|
70
|
-
}
|
package/lib/FormDataInput.js
DELETED
package/lib/FormDataInput.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FormDataInput.js","sourceRoot":"","sources":["../src/FormDataInput.ts"],"names":[],"mappings":""}
|
package/lib/HttpError.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { HttpError } from "@typia/utils";
|
package/lib/HttpError.js
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.HttpError = void 0;
|
|
4
|
-
var utils_1 = require("@typia/utils");
|
|
5
|
-
Object.defineProperty(exports, "HttpError", { enumerable: true, get: function () { return utils_1.HttpError; } });
|
|
6
|
-
//# sourceMappingURL=HttpError.js.map
|
package/lib/HttpError.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"HttpError.js","sourceRoot":"","sources":["../src/HttpError.ts"],"names":[],"mappings":";;;AAAA,sCAAyC;AAAhC,kGAAA,SAAS,OAAA"}
|
package/lib/IConnection.d.ts
DELETED
|
@@ -1,165 +0,0 @@
|
|
|
1
|
-
import { IEncryptionPassword } from "./IEncryptionPassword";
|
|
2
|
-
import { IFetchEvent } from "./IFetchEvent";
|
|
3
|
-
/**
|
|
4
|
-
* Connection information.
|
|
5
|
-
*
|
|
6
|
-
* `IConnection` is an interface ttype who represents connection information of
|
|
7
|
-
* the remote HTTP server. You can target the remote HTTP server by wring the
|
|
8
|
-
* {@link IConnection.host} variable down. Also, you can configure special header
|
|
9
|
-
* values by specializing the {@link IConnection.headers} variable.
|
|
10
|
-
*
|
|
11
|
-
* If the remote HTTP server encrypts or decrypts its body data through the
|
|
12
|
-
* AES-128/256 algorithm, specify the {@link IConnection.encryption} with
|
|
13
|
-
* {@link IEncryptionPassword} or {@link IEncryptionPassword.Closure} variable.
|
|
14
|
-
*
|
|
15
|
-
* @author Jenogho Nam - https://github.com/samchon
|
|
16
|
-
* @author Seungjun We - https://github.com/SeungjunWe
|
|
17
|
-
*/
|
|
18
|
-
export interface IConnection<Headers extends object | undefined = object | undefined> {
|
|
19
|
-
/** Host address of the remote HTTP server. */
|
|
20
|
-
host: string;
|
|
21
|
-
/** Header values delivered to the remote HTTP server. */
|
|
22
|
-
headers?: Record<string, IConnection.HeaderValue> & IConnection.Headerify<Headers>;
|
|
23
|
-
/**
|
|
24
|
-
* Use simulation mode.
|
|
25
|
-
*
|
|
26
|
-
* If you configure this property to be `true`, your SDK library does not send
|
|
27
|
-
* any request to remote backend server, but just returns random data
|
|
28
|
-
* generated by `typia.random<T>()` function with request data validation.
|
|
29
|
-
*
|
|
30
|
-
* By the way, to utilize this simulation mode, SDK library must be generated
|
|
31
|
-
* with {@link INestiaConfig.simulate} option, too. Open `nestia.config.ts`
|
|
32
|
-
* file, and configure {@link INestiaConfig.simulate} property to be `true`.
|
|
33
|
-
* Them, newly generated SDK library would have a built-in mock-up data
|
|
34
|
-
* generator.
|
|
35
|
-
*
|
|
36
|
-
* @default false
|
|
37
|
-
*/
|
|
38
|
-
simulate?: boolean;
|
|
39
|
-
/**
|
|
40
|
-
* Logger function.
|
|
41
|
-
*
|
|
42
|
-
* This function is called when the fetch event is completed.
|
|
43
|
-
*
|
|
44
|
-
* @param event Event information of the fetch event.
|
|
45
|
-
*/
|
|
46
|
-
logger?: (event: IFetchEvent) => Promise<void>;
|
|
47
|
-
/**
|
|
48
|
-
* Encryption password of its closure function.
|
|
49
|
-
*
|
|
50
|
-
* Define it only when target backend server is encrypting body data through
|
|
51
|
-
* `@EncryptedRoute` or `@EncryptedBody` decorators of `@nestia/core` for
|
|
52
|
-
* security reason.
|
|
53
|
-
*/
|
|
54
|
-
encryption?: IEncryptionPassword | IEncryptionPassword.Closure;
|
|
55
|
-
/** Additional options for the `fetch` function. */
|
|
56
|
-
options?: IConnection.IOptions;
|
|
57
|
-
/**
|
|
58
|
-
* Custom fetch function.
|
|
59
|
-
*
|
|
60
|
-
* If you want to use custom `fetch` function instead of built-in, assign your
|
|
61
|
-
* custom `fetch` function into this property.
|
|
62
|
-
*
|
|
63
|
-
* For reference, the `fetch` function has started to be supported since
|
|
64
|
-
* version 20 of NodeJS. Therefore, if you are using NodeJS version 19 or
|
|
65
|
-
* lower, you have to assign the `node-fetch` module into this property.
|
|
66
|
-
*/
|
|
67
|
-
fetch?: typeof fetch;
|
|
68
|
-
}
|
|
69
|
-
export declare namespace IConnection {
|
|
70
|
-
/**
|
|
71
|
-
* Additional options for the `fetch` function.
|
|
72
|
-
*
|
|
73
|
-
* Almost same with {@link RequestInit} type of the {@link fetch} function, but
|
|
74
|
-
* `body`, `headers` and `method` properties are omitted.
|
|
75
|
-
*
|
|
76
|
-
* The reason why defining duplicated definition of {@link RequestInit} is for
|
|
77
|
-
* legacy NodeJS environments, which does not have the {@link fetch} function
|
|
78
|
-
* type.
|
|
79
|
-
*/
|
|
80
|
-
interface IOptions {
|
|
81
|
-
/**
|
|
82
|
-
* A string indicating how the request will interact with the browser's
|
|
83
|
-
* cache to set request's cache.
|
|
84
|
-
*/
|
|
85
|
-
cache?: "default" | "force-cache" | "no-cache" | "no-store" | "only-if-cached" | "reload";
|
|
86
|
-
/**
|
|
87
|
-
* A string indicating whether credentials will be sent with the request
|
|
88
|
-
* always, never, or only when sent to a same-origin URL. Sets request's
|
|
89
|
-
* credentials.
|
|
90
|
-
*/
|
|
91
|
-
credentials?: "omit" | "same-origin" | "include";
|
|
92
|
-
/**
|
|
93
|
-
* A cryptographic hash of the resource to be fetched by request.
|
|
94
|
-
*
|
|
95
|
-
* Sets request's integrity.
|
|
96
|
-
*/
|
|
97
|
-
integrity?: string;
|
|
98
|
-
/** A boolean to set request's keepalive. */
|
|
99
|
-
keepalive?: boolean;
|
|
100
|
-
/**
|
|
101
|
-
* A string to indicate whether the request will use CORS, or will be
|
|
102
|
-
* restricted to same-origin URLs.
|
|
103
|
-
*
|
|
104
|
-
* Sets request's mode.
|
|
105
|
-
*/
|
|
106
|
-
mode?: "cors" | "navigate" | "no-cors" | "same-origin";
|
|
107
|
-
/**
|
|
108
|
-
* A string indicating whether request follows redirects, results in an
|
|
109
|
-
* error upon encountering a redirect, or returns the redirect (in an opaque
|
|
110
|
-
* fashion).
|
|
111
|
-
*
|
|
112
|
-
* Sets request's redirect.
|
|
113
|
-
*/
|
|
114
|
-
redirect?: "error" | "follow" | "manual";
|
|
115
|
-
/**
|
|
116
|
-
* A string whose value is a same-origin URL, "about:client", or the empty
|
|
117
|
-
* string, to set request's referrer.
|
|
118
|
-
*/
|
|
119
|
-
referrer?: string;
|
|
120
|
-
/** A referrer policy to set request's referrerPolicy. */
|
|
121
|
-
referrerPolicy?: "" | "no-referrer" | "no-referrer-when-downgrade" | "origin" | "origin-when-cross-origin" | "same-origin" | "strict-origin" | "strict-origin-when-cross-origin" | "unsafe-url";
|
|
122
|
-
/** An AbortSignal to set request's signal. */
|
|
123
|
-
signal?: AbortSignal | null;
|
|
124
|
-
}
|
|
125
|
-
/**
|
|
126
|
-
* Type of allowed header values.
|
|
127
|
-
*
|
|
128
|
-
* Only atomic or array of atomic values are allowed.
|
|
129
|
-
*/
|
|
130
|
-
type HeaderValue = string | boolean | number | bigint | string | Array<boolean> | Array<number> | Array<bigint> | Array<number> | Array<string>;
|
|
131
|
-
/**
|
|
132
|
-
* Type of headers
|
|
133
|
-
*
|
|
134
|
-
* `Headerify` removes every properties that are not allowed in the HTTP
|
|
135
|
-
* headers type.
|
|
136
|
-
*
|
|
137
|
-
* Below are list of prohibited in HTTP headers.
|
|
138
|
-
*
|
|
139
|
-
* 1. Value type one of {@link HeaderValue}
|
|
140
|
-
* 2. Key is "set-cookie", but value is not an Array type
|
|
141
|
-
* 3. Key is one of them, but value is Array type
|
|
142
|
-
*
|
|
143
|
-
* - "age"
|
|
144
|
-
* - "authorization"
|
|
145
|
-
* - "content-length"
|
|
146
|
-
* - "content-type"
|
|
147
|
-
* - "etag"
|
|
148
|
-
* - "expires"
|
|
149
|
-
* - "from"
|
|
150
|
-
* - "host"
|
|
151
|
-
* - "if-modified-since"
|
|
152
|
-
* - "if-unmodified-since"
|
|
153
|
-
* - "last-modified"
|
|
154
|
-
* - "location"
|
|
155
|
-
* - "max-forwards"
|
|
156
|
-
* - "proxy-authorization"
|
|
157
|
-
* - "referer"
|
|
158
|
-
* - "retry-after"
|
|
159
|
-
* - "server"
|
|
160
|
-
* - "user-agent"
|
|
161
|
-
*/
|
|
162
|
-
type Headerify<T extends object | undefined> = {
|
|
163
|
-
[P in keyof T]?: T[P] extends HeaderValue | undefined ? P extends string ? Lowercase<P> extends "set-cookie" ? T[P] extends Array<HeaderValue> ? T[P] | undefined : never : Lowercase<P> extends "age" | "authorization" | "content-length" | "content-type" | "etag" | "expires" | "from" | "host" | "if-modified-since" | "if-unmodified-since" | "last-modified" | "location" | "max-forwards" | "proxy-authorization" | "referer" | "retry-after" | "server" | "user-agent" ? T[P] extends Array<HeaderValue> ? never : T[P] | undefined : T[P] | undefined : never : never;
|
|
164
|
-
};
|
|
165
|
-
}
|
package/lib/IConnection.js
DELETED
package/lib/IConnection.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IConnection.js","sourceRoot":"","sources":["../src/IConnection.ts"],"names":[],"mappings":""}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { IConnection } from "./IConnection";
|
|
2
|
-
/**
|
|
3
|
-
* Encryption password.
|
|
4
|
-
*
|
|
5
|
-
* `IEncryptionPassword` is a type of interface who represents encryption
|
|
6
|
-
* password used by the {@link Fetcher} with AES-128/256 algorithm. If your
|
|
7
|
-
* encryption password is not fixed but changes according to the input content,
|
|
8
|
-
* you can utilize the {@link IEncryptionPassword.Closure} function type.
|
|
9
|
-
*
|
|
10
|
-
* @author Jeongho Nam - https://github.com/samchon
|
|
11
|
-
*/
|
|
12
|
-
export interface IEncryptionPassword {
|
|
13
|
-
/** Secret key. */
|
|
14
|
-
key: string;
|
|
15
|
-
/** Initialization Vector. */
|
|
16
|
-
iv: string;
|
|
17
|
-
}
|
|
18
|
-
export declare namespace IEncryptionPassword {
|
|
19
|
-
/**
|
|
20
|
-
* Type of a closure function returning the {@link IEncryptionPassword} object.
|
|
21
|
-
*
|
|
22
|
-
* `IEncryptionPassword.Closure` is a type of closure function who are
|
|
23
|
-
* returning the {@link IEncryptionPassword} object. It would be used when your
|
|
24
|
-
* encryption password be changed according to the input content.
|
|
25
|
-
*/
|
|
26
|
-
interface Closure {
|
|
27
|
-
/**
|
|
28
|
-
* Encryption password getter.
|
|
29
|
-
*
|
|
30
|
-
* @param props Properties for predication
|
|
31
|
-
* @returns Encryption password
|
|
32
|
-
*/
|
|
33
|
-
(props: IProps): IEncryptionPassword;
|
|
34
|
-
}
|
|
35
|
-
/** Properties for the closure. */
|
|
36
|
-
interface IProps {
|
|
37
|
-
headers: Record<string, IConnection.HeaderValue | undefined>;
|
|
38
|
-
body: string;
|
|
39
|
-
direction: "encode" | "decode";
|
|
40
|
-
}
|
|
41
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IEncryptionPassword.js","sourceRoot":"","sources":["../src/IEncryptionPassword.ts"],"names":[],"mappings":""}
|
package/lib/IFetchEvent.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { IFetchRoute } from "./IFetchRoute";
|
|
2
|
-
export interface IFetchEvent {
|
|
3
|
-
route: IFetchRoute<"DELETE" | "GET" | "HEAD" | "PATCH" | "POST" | "PUT">;
|
|
4
|
-
path: string;
|
|
5
|
-
status: number | null;
|
|
6
|
-
input: any;
|
|
7
|
-
output: any;
|
|
8
|
-
started_at: Date;
|
|
9
|
-
respond_at: Date | null;
|
|
10
|
-
completed_at: Date;
|
|
11
|
-
}
|
package/lib/IFetchEvent.js
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
// export namespace IFetchEvent {
|
|
4
|
-
// export interface IFunction {
|
|
5
|
-
// (connection: IConnection, ...args: any[]): Promise<any>;
|
|
6
|
-
// METADATA: {
|
|
7
|
-
// method: "GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "HEAD" | "OPTIONS";
|
|
8
|
-
// path: string;
|
|
9
|
-
// request: null | {
|
|
10
|
-
// type: string;
|
|
11
|
-
// encrypted: boolean;
|
|
12
|
-
// };
|
|
13
|
-
// response: null | {
|
|
14
|
-
// type: string;
|
|
15
|
-
// encrypted: boolean;
|
|
16
|
-
// };
|
|
17
|
-
// };
|
|
18
|
-
// status: null | number;
|
|
19
|
-
// }
|
|
20
|
-
// }
|
|
21
|
-
//# sourceMappingURL=IFetchEvent.js.map
|
package/lib/IFetchEvent.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IFetchEvent.js","sourceRoot":"","sources":["../src/IFetchEvent.ts"],"names":[],"mappings":";;AAaA,iCAAiC;AACjC,iCAAiC;AACjC,+DAA+D;AAC/D,kBAAkB;AAClB,kFAAkF;AAClF,sBAAsB;AACtB,0BAA0B;AAC1B,wBAAwB;AACxB,8BAA8B;AAC9B,WAAW;AACX,2BAA2B;AAC3B,wBAAwB;AACxB,8BAA8B;AAC9B,WAAW;AACX,SAAS;AACT,6BAA6B;AAC7B,MAAM;AACN,IAAI"}
|
package/lib/IFetchRoute.d.ts
DELETED
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Properties of remote API route.
|
|
3
|
-
*
|
|
4
|
-
* @author Jeongho Nam - https://github.com/samchon
|
|
5
|
-
*/
|
|
6
|
-
export interface IFetchRoute<Method extends "HEAD" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE"> {
|
|
7
|
-
/** Method of the HTTP request. */
|
|
8
|
-
method: Method;
|
|
9
|
-
/** Path of the HTTP request. */
|
|
10
|
-
path: string;
|
|
11
|
-
/**
|
|
12
|
-
* Path template.
|
|
13
|
-
*
|
|
14
|
-
* Filled since 3.2.2 version.
|
|
15
|
-
*/
|
|
16
|
-
template?: string;
|
|
17
|
-
/** Request body data info. */
|
|
18
|
-
request: Method extends "DELETE" | "POST" | "PUT" | "PATCH" ? IFetchRoute.IBody | null : null;
|
|
19
|
-
/** Response body data info. */
|
|
20
|
-
response: Method extends "HEAD" ? null : IFetchRoute.IBody;
|
|
21
|
-
/** When special status code being used. */
|
|
22
|
-
status: number | null;
|
|
23
|
-
/**
|
|
24
|
-
* Parser of the query string.
|
|
25
|
-
*
|
|
26
|
-
* If content type of response body is `application/x-www-form-urlencoded`,
|
|
27
|
-
* then this `parseQuery` function would be called.
|
|
28
|
-
*
|
|
29
|
-
* If you've forgotten to configuring this `parseQuery` property about the
|
|
30
|
-
* `application/x-www-form-urlencoded` typed response body data, then only the
|
|
31
|
-
* `URLSearchParams` typed instance would be returned instead.
|
|
32
|
-
*/
|
|
33
|
-
parseQuery?(input: URLSearchParams): any;
|
|
34
|
-
}
|
|
35
|
-
export declare namespace IFetchRoute {
|
|
36
|
-
/**
|
|
37
|
-
* Metadata of body.
|
|
38
|
-
*
|
|
39
|
-
* Describes how content-type being used in body, and whether encrypted or
|
|
40
|
-
* not.
|
|
41
|
-
*/
|
|
42
|
-
interface IBody {
|
|
43
|
-
type: "application/json" | "application/x-www-form-urlencoded" | "multipart/form-data" | "text/plain";
|
|
44
|
-
encrypted?: boolean;
|
|
45
|
-
}
|
|
46
|
-
}
|
package/lib/IFetchRoute.js
DELETED
package/lib/IFetchRoute.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IFetchRoute.js","sourceRoot":"","sources":["../src/IFetchRoute.ts"],"names":[],"mappings":""}
|
package/lib/IPropagation.d.ts
DELETED
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Propagation type.
|
|
3
|
-
*
|
|
4
|
-
* `IPropagation` is a type gathering all possible status codes and their body
|
|
5
|
-
* data types as a discriminated union type. You can specify the status code and
|
|
6
|
-
* its body data type just by using conditional statement like below.
|
|
7
|
-
*
|
|
8
|
-
* ```typescript
|
|
9
|
-
* type Output = IPropagation<{
|
|
10
|
-
* 200: ISeller.IAuthorized;
|
|
11
|
-
* 400: TypeGuardError.IProps;
|
|
12
|
-
* >};
|
|
13
|
-
*
|
|
14
|
-
* const output: Output = await sdk.sellers.authenticate.join(input);
|
|
15
|
-
* if (output.success) {
|
|
16
|
-
* // automatically casted to "ISeller.IAuthorized" type
|
|
17
|
-
* const authorized: ISeller.IAuthorized = output.data;
|
|
18
|
-
* } else if (output.status === 400) {
|
|
19
|
-
* // automatically casted to "TypeGuardError.IProps" type
|
|
20
|
-
* const error: TypeGuardError.IProps = output.data;
|
|
21
|
-
* } else {
|
|
22
|
-
* // unknown type when out of pre-defined status codes
|
|
23
|
-
* const result: unknown = output.data;
|
|
24
|
-
* }
|
|
25
|
-
* ```
|
|
26
|
-
*
|
|
27
|
-
* For reference, this `IPropagation` type is utilized by SDK library generated
|
|
28
|
-
* by `@nestia/sdk`, when you've configured {@link INestiaConfig.propagate} to be
|
|
29
|
-
* `true`. In that case, SDK functions generated by `@nestia/sdk` no more
|
|
30
|
-
* returns response DTO typed data directly, but returns this `IPropagation`
|
|
31
|
-
* typed object instead.
|
|
32
|
-
*
|
|
33
|
-
* @author Jeongho Nam - https://github.com/samchon
|
|
34
|
-
* @template StatusMap Map of status code and its body data type.
|
|
35
|
-
* @template Success Default success status code.
|
|
36
|
-
*/
|
|
37
|
-
export type IPropagation<StatusMap extends {
|
|
38
|
-
[P in IPropagation.Status]?: any;
|
|
39
|
-
}, Success extends number = 200 | 201> = {
|
|
40
|
-
[P in keyof StatusMap]: IPropagation.IBranch<P extends Success ? true : false, P, StatusMap[P]>;
|
|
41
|
-
}[keyof StatusMap] | IPropagation.IBranch<false, unknown, unknown>;
|
|
42
|
-
export declare namespace IPropagation {
|
|
43
|
-
/**
|
|
44
|
-
* Type of configurable status codes.
|
|
45
|
-
*
|
|
46
|
-
* The special characters like `2XX`, `3XX`, `4XX`, `5XX` are meaning the
|
|
47
|
-
* range of status codes. If `5XX` is specified, it means the status code is
|
|
48
|
-
* in the range of `500` to `599`.
|
|
49
|
-
*/
|
|
50
|
-
export type Status = number | "2XX" | "3XX" | "4XX" | "5XX";
|
|
51
|
-
/**
|
|
52
|
-
* Branch type of propagation.
|
|
53
|
-
*
|
|
54
|
-
* `IPropagation.IBranch` is a branch type composing `IPropagation` type,
|
|
55
|
-
* which is gathering all possible status codes and their body data types as a
|
|
56
|
-
* union type.
|
|
57
|
-
*/
|
|
58
|
-
export interface IBranch<Success extends boolean, StatusValue, BodyData> {
|
|
59
|
-
success: Success;
|
|
60
|
-
status: StatusValue extends "2XX" | "3XX" | "4XX" | "5XX" ? StatusRange<StatusValue> : StatusValue extends number ? StatusValue : never;
|
|
61
|
-
data: BodyData;
|
|
62
|
-
headers: Record<string, string | string[]>;
|
|
63
|
-
}
|
|
64
|
-
/** Range of status codes by the first digit. */
|
|
65
|
-
export type StatusRange<T extends "2XX" | "3XX" | "4XX" | "5XX"> = T extends 0 ? IntRange<200, 299> : T extends 3 ? IntRange<300, 399> : T extends 4 ? IntRange<400, 499> : IntRange<500, 599>;
|
|
66
|
-
type IntRange<F extends number, T extends number> = Exclude<Enumerate<T>, Enumerate<F>>;
|
|
67
|
-
type Enumerate<N extends number, Acc extends number[] = []> = Acc["length"] extends N ? Acc[number] : Enumerate<N, [...Acc, Acc["length"]]>;
|
|
68
|
-
export {};
|
|
69
|
-
}
|
package/lib/IPropagation.js
DELETED
package/lib/IPropagation.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IPropagation.js","sourceRoot":"","sources":["../src/IPropagation.ts"],"names":[],"mappings":""}
|
package/lib/NestiaSimulator.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export declare namespace NestiaSimulator {
|
|
2
|
-
interface IProps {
|
|
3
|
-
host: string;
|
|
4
|
-
path: string;
|
|
5
|
-
method: "GET" | "POST" | "PATCH" | "PUT" | "DELETE";
|
|
6
|
-
contentType: string;
|
|
7
|
-
}
|
|
8
|
-
const assert: (props: IProps) => {
|
|
9
|
-
param: (name: string) => <T>(task: () => T) => void;
|
|
10
|
-
query: <T>(task: () => T) => void;
|
|
11
|
-
body: <T>(task: () => T) => void;
|
|
12
|
-
};
|
|
13
|
-
}
|
package/lib/NestiaSimulator.js
DELETED
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NestiaSimulator = void 0;
|
|
4
|
-
const HttpError_1 = require("./HttpError");
|
|
5
|
-
var NestiaSimulator;
|
|
6
|
-
(function (NestiaSimulator) {
|
|
7
|
-
NestiaSimulator.assert = (props) => {
|
|
8
|
-
return {
|
|
9
|
-
param: param(props),
|
|
10
|
-
query: query(props),
|
|
11
|
-
body: body(props),
|
|
12
|
-
};
|
|
13
|
-
};
|
|
14
|
-
const param = (props) => (name) => (task) => {
|
|
15
|
-
validate((exp) => `URL parameter "${name}" is not ${exp.expected} type.`)(props)(task);
|
|
16
|
-
};
|
|
17
|
-
const query = (props) => (task) => validate(() => "Request query parameters are not following the promised type.")(props)(task);
|
|
18
|
-
const body = (props) => (task) => validate(() => "Request body is not following the promised type.")(props)(task);
|
|
19
|
-
const validate = (message, path) => (props) => (task) => {
|
|
20
|
-
try {
|
|
21
|
-
task();
|
|
22
|
-
}
|
|
23
|
-
catch (exp) {
|
|
24
|
-
if (isTypeGuardError(exp))
|
|
25
|
-
throw new HttpError_1.HttpError(props.method, props.host + props.path, 400, {
|
|
26
|
-
"Content-Type": props.contentType,
|
|
27
|
-
}, JSON.stringify({
|
|
28
|
-
method: exp.method,
|
|
29
|
-
path: path !== null && path !== void 0 ? path : exp.path,
|
|
30
|
-
expected: exp.expected,
|
|
31
|
-
value: exp.value,
|
|
32
|
-
message: message(exp),
|
|
33
|
-
}));
|
|
34
|
-
throw exp;
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
})(NestiaSimulator || (exports.NestiaSimulator = NestiaSimulator = {}));
|
|
38
|
-
const isTypeGuardError = (input) => "string" === typeof input.method &&
|
|
39
|
-
(undefined === input.path || "string" === typeof input.path) &&
|
|
40
|
-
"string" === typeof input.expected &&
|
|
41
|
-
"string" === typeof input.name &&
|
|
42
|
-
"string" === typeof input.message &&
|
|
43
|
-
(undefined === input.stack || "string" === typeof input.stack);
|
|
44
|
-
//# sourceMappingURL=NestiaSimulator.js.map
|