eve-esi-types 3.2.4 → 3.2.7

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.
Files changed (55) hide show
  1. package/CHANGELOG.md +39 -0
  2. package/README.md +87 -63
  3. package/{v2 → dist/v2}/esi-tagged-types.d.ts +77 -44
  4. package/{v2 → dist/v2}/experimental-esi-types.d.ts +139 -29
  5. package/dist/v2/index.d.ts +621 -0
  6. package/{v2 → dist/v2}/response-map.d.ts +1 -1
  7. package/{v2 → dist/v2}/types-index.d.ts +1 -1
  8. package/dist/v2/types-util.d.ts +281 -0
  9. package/dist/v2/util.d.ts +149 -0
  10. package/lib/console-util.mjs +1 -1
  11. package/lib/request-api.d.mts +4 -4
  12. package/lib/request-api.mjs +15 -16
  13. package/lib/rq-util.d.mts +76 -15
  14. package/lib/rq-util.mjs +122 -48
  15. package/lib/tagged-request-api.d.mts +2 -2
  16. package/lib/tagged-request-api.mjs +2 -2
  17. package/minimal-rq.mjs +5 -5
  18. package/package.json +5 -5
  19. package/request-v3.d.mts +1 -8
  20. package/request-v3.mjs +16 -19
  21. package/tagged-rq.mjs +17 -6
  22. package/{jsconfig.json → tsconfig.json} +5 -5
  23. package/v2/index.d.ts +0 -515
  24. package/v2/types-util.d.ts +0 -171
  25. package/v2/util.d.ts +0 -72
  26. /package/{v2 → dist/v2}/globals/alliance.d.ts +0 -0
  27. /package/{v2 → dist/v2}/globals/assets.d.ts +0 -0
  28. /package/{v2 → dist/v2}/globals/calendar.d.ts +0 -0
  29. /package/{v2 → dist/v2}/globals/character.d.ts +0 -0
  30. /package/{v2 → dist/v2}/globals/clones.d.ts +0 -0
  31. /package/{v2 → dist/v2}/globals/contacts.d.ts +0 -0
  32. /package/{v2 → dist/v2}/globals/contracts.d.ts +0 -0
  33. /package/{v2 → dist/v2}/globals/corporation.d.ts +0 -0
  34. /package/{v2 → dist/v2}/globals/dogma.d.ts +0 -0
  35. /package/{v2 → dist/v2}/globals/extra-types.d.ts +0 -0
  36. /package/{v2 → dist/v2}/globals/factionwarfare.d.ts +0 -0
  37. /package/{v2 → dist/v2}/globals/fittings.d.ts +0 -0
  38. /package/{v2 → dist/v2}/globals/fleets.d.ts +0 -0
  39. /package/{v2 → dist/v2}/globals/incursions.d.ts +0 -0
  40. /package/{v2 → dist/v2}/globals/industry.d.ts +0 -0
  41. /package/{v2 → dist/v2}/globals/insurance.d.ts +0 -0
  42. /package/{v2 → dist/v2}/globals/killmails.d.ts +0 -0
  43. /package/{v2 → dist/v2}/globals/location.d.ts +0 -0
  44. /package/{v2 → dist/v2}/globals/loyalty.d.ts +0 -0
  45. /package/{v2 → dist/v2}/globals/mail.d.ts +0 -0
  46. /package/{v2 → dist/v2}/globals/market.d.ts +0 -0
  47. /package/{v2 → dist/v2}/globals/planetaryinteraction.d.ts +0 -0
  48. /package/{v2 → dist/v2}/globals/routes.d.ts +0 -0
  49. /package/{v2 → dist/v2}/globals/search.d.ts +0 -0
  50. /package/{v2 → dist/v2}/globals/skills.d.ts +0 -0
  51. /package/{v2 → dist/v2}/globals/sovereignty.d.ts +0 -0
  52. /package/{v2 → dist/v2}/globals/status.d.ts +0 -0
  53. /package/{v2 → dist/v2}/globals/universe.d.ts +0 -0
  54. /package/{v2 → dist/v2}/globals/wallet.d.ts +0 -0
  55. /package/{v2 → dist/v2}/globals/wars.d.ts +0 -0
package/CHANGELOG.md CHANGED
@@ -2,6 +2,45 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## [3.2.7] - 2025-04-28
6
+
7
+ ### 🚜 Refactor
8
+
9
+ - Add ESIEntryParamKeys, ESIEntryExtraKeys & ResolveEndpointRequest types
10
+
11
+ ### ⚙️ Miscellaneous Tasks
12
+
13
+ - Update CHANGELOG.md
14
+ - Update JSDoc (rename EPX to EPO and add acronym definition)
15
+ - Update CHANGELOG.md
16
+ - Bump version to v3.2.7
17
+
18
+ ## [3.2.6] - 2025-04-24
19
+
20
+ ### 🐛 Bug Fixes
21
+
22
+ - `normalizeOptions` bug
23
+
24
+ ### ⚙️ Miscellaneous Tasks
25
+
26
+ - Update CHANGELOG.md
27
+ - Update "main" field in package.json to point to dist folder
28
+ - Bump version to v3.2.6
29
+
30
+ ## [3.2.5] - 2025-04-24
31
+
32
+ ### 💼 Other
33
+
34
+ - Refactor v2/experimental-esi-types.d.ts
35
+
36
+ ### ⚙️ Miscellaneous Tasks
37
+
38
+ - Update CHANGELOG.md
39
+ - Relocate v2 files to dist/v2 directory
40
+ - Update import paths to reflect new structure
41
+ - Update jsconfig.json for improved path resolution
42
+ - Bump version to v3.2.5
43
+
5
44
  ## [3.2.4] - 2025-04-22
6
45
 
7
46
  ### 🚜 Refactor
package/README.md CHANGED
@@ -1,105 +1,129 @@
1
+
1
2
  # eve-esi-types
2
- Extracted main types of ESI. Used for ESI request response types.
3
+ Extracted main types of ESI (EVE Swagger Interface). This package is designed to handle ESI request and response types effectively.
3
4
 
4
- ## Usage
5
+ ---
6
+
7
+ ## Table of Contents
8
+ 1. [Overview](#overview)
9
+ 2. [Installation](#installation)
10
+ 3. [Usage](#usage)
11
+ 4. [API Overview](#api-overview)
12
+ 5. [Version Highlights](#version-highlights)
13
+ - [v3.2.7](#v327)
14
+ - [v3.0.0](#v300)
15
+ - [v2.3.0](#v230)
16
+ 6. [References](#references)
5
17
 
6
- > This package is configured to use version 2 only.
18
+ ---
7
19
 
8
- + If you need to use version 1, please refer to the following link:
9
- [eve-esi-types v1](https://github.com/jeffy-g/eve-esi-types/tree/version-1.x)
20
+ ## Overview
21
+ `eve-esi-types` helps developers interact with the EVE Online ESI API while leveraging strong TypeScript typings.
10
22
 
11
- > Sample code is provided -> [`request-v3.mjs`](./request-v3.mjs)
23
+ This package ensures type safety for ESI request parameters, response handling, and authentication requirements.
12
24
 
13
- ```shell
14
- $ node request-v3.mjs
25
+ ---
26
+
27
+ ## Installation
28
+
29
+ ```bash
30
+ npm install eve-esi-types
15
31
  ```
16
32
 
17
- ## API
33
+ ---
34
+
35
+ ## Usage
18
36
 
19
- > The following function signature allows you to benefit from `eve-esi-types`.
20
- > By specifying the method (`get`, `post`, `put`, `delete`) for each `endpoint`,
21
- > you can determine the result type of the ESI request, what query parameters are required,
22
- > and whether OAuth authentication is necessary (`auth: true`).
37
+ This package is configured to **use ESI version 2 by default**.
38
+ If you need to work with version 1, refer to the [v1 branch](https://github.com/jeffy-g/eve-esi-types/tree/version-1.x).
23
39
 
24
- ```ts
25
- // This function signature has been removed in version 3.x
26
- // export declare function fire<
27
- // M extends TESIEntryMethod,
28
- // EP extends keyof TESIResponseOKMap[M],
29
- // P2 extends IfParameterizedPath<EP, Opt>,
30
- // Opt extends IdentifyParameters<TESIResponseOKMap[M][EP], ESIRequestOptions>,
31
- // R extends InferESIResponseResult<M, EP>
32
- // >(mthd: M, endp: EP, pathParams?: P2, opt?: Opt): Promise<R>;
40
+ ### Example Usage
41
+ A sample script, [`request-v3.mjs`](./request-v3.mjs), is provided.
42
+
43
+ ```bash
44
+ node request-v3.mjs
33
45
  ```
34
46
 
35
- ## New Features in v2.3.0
47
+ ---
36
48
 
37
- ### ESI Tagged Types
49
+ ## API Overview
38
50
 
39
- > Introduced intuitive ESI request handling using "tags" from the EVE Swagger JSON.
51
+ The core export of this package is the `TESIRequestFunctionSignature2` type. It specifies the required endpoint,
40
52
 
41
- ### ~~injectESIRequestBody~~
53
+ HTTP method, query parameters, OAuth requirement, and response type for ESI requests.
42
54
 
43
- > Utilized ~~`injectESIRequestBody`~~ to generate ESI request API objects with narrowed endpoints by accessing camel-cased "tags".
55
+ ### Main Function Signature
44
56
 
45
57
  ```ts
46
- import * as taggedApi from "eve-esi-types/lib/tagged-request-api.mjs";
47
-
48
- // `injectESIRequestBody` has been removed in version 3.x
49
- // const esiRequest = taggedApi.injectESIRequestBody(...);
50
- // const ret = await esiRequest.universe.get("/universe/structures/", { query: { filter: "market" }});
58
+ type TESIRequestFunctionSignature2<ActualOpt extends Record<string, unknown>> = <
59
+ Mtd extends TESIEntryMethod,
60
+ REP extends ReplacePathParams<ESIEndpointOf<Mtd>> | ESIEndpointOf<Mtd>,
61
+ EPO extends ResolvedEndpoint<Mtd, REP>,
62
+ Params extends ResolveEndpointParameters<Mtd, REP, EPO, ActualOpt>,
63
+ Opt extends Params["finalOptions"]
64
+ >(
65
+ method: Mtd,
66
+ endpoint: REP,
67
+ ...options: Params["optionIsRequire"] extends 1 ? [Opt] : [Opt?]
68
+ ) => Promise<Params["result"]>;
51
69
  ```
52
70
 
53
- + or
71
+ ### Authentication via Environment Variable (v3.2.7+)
54
72
 
55
- ```ts
56
- // Minimal default ESI request body implementation
57
- import { esi } from "eve-esi-types/lib/tagged-request-api.mjs";
73
+ You can enable authenticated requests by setting the environment variable `OAUTH_TOKEN` (for testing):
58
74
 
59
- const ret = await esi.universe.get("/universe/structures/", { query: { filter: "market" }});
75
+ ```bash
76
+ export OAUTH_TOKEN=<Your Access Token>
60
77
  ```
61
78
 
62
- ## New Features in v3.0.0
79
+ ---
80
+
81
+ ## Version Highlights
82
+
83
+ ### v3.2.7
84
+ - Added support for specifying the `OAUTH_TOKEN` environment variable.
85
+ - Allows authenticated tests to run successfully by providing an OAuth access token.
63
86
 
64
- ### `TESIRequestFunctionSignature` has been renamed to `TESIRequestFunctionSignature2` and the generic parameters have been changed.
87
+ ---
65
88
 
66
- > `RealEP` and `EP` help maintain endpoint inference.
67
- > With `RealEP`, TypeScript inference partially lists the possible endpoints while allowing for path parameter replacement.
89
+ ### v3.0.0
90
+ - Renamed `TESIRequestFunctionSignature` to `TESIRequestFunctionSignature2`.
91
+ - Improved endpoint inference (`RealEP` and `EP`) for better TypeScript type safety.
68
92
 
93
+ #### New API Example
94
+ Reusable, narrowing-focused API request using `decoreateESIRequestBody`:
69
95
 
70
96
  ```ts
71
- type TESIRequestFunctionSignature2<ActualOpt> = <
72
- M extends TESIEntryMethod,
73
- RealEP extends ReplacePathParams<keyof TESIResponseOKMap[M] & string> | keyof TESIResponseOKMap[M],
74
- EP extends InferEndpointOrigin<RealEP, keyof TESIResponseOKMap[M]> extends never ? RealEP : InferEndpointOrigin<RealEP, keyof TESIResponseOKMap[M]>,
75
- // If RealEP points to an endpoint origin (not a replaced endpoint), the path parameter is required
76
- PathParams extends RealEP extends EP ? IfNeedPathParams<EP> : TPathParamsNever,
77
- Opt extends IdentifyParameters<TESIResponseOKMap[M][EP], ActualOpt & PathParams>,
78
- R extends InferESIResponseResult<M, EP>
79
- >(method: M, endpoint: RealEP, options?: Opt) => Promise<R>;
97
+ import * as taggedApi from "eve-esi-types/lib/tagged-request-api.mjs";
98
+
99
+ const esiRequest = taggedApi.decoreateESIRequestBody(...);
100
+ const response = await esiRequest.universe.get("/universe/structures/", { query: { filter: "market" } });
80
101
  ```
81
102
 
82
- + NOTE: Accordingly, the generic parameters for other request function signatures have also been changed, with "2" appended to their names.
103
+ #### Other Renamed Signatures
104
+ - `IESIRequestFunction -> IESIRequestFunction2`
105
+ - `TESIRequestFunctionMethods -> TESIRequestFunctionMethods2`
83
106
 
84
- + `IESIRequestFunction` -> `IESIRequestFunction2`
85
- + `TESIRequestFunctionMethods` -> `TESIRequestFunctionMethods2`
86
- + `TESIRequestFunctionEachMethod` -> `TESIRequestFunctionEachMethod2`
87
- + etc. Also, `v2/esi-tagged-types.d.ts` too
107
+ ---
88
108
 
89
- ### decoreateESIRequestBody
109
+ ### v2.3.0
110
+ - Introduced intuitive ESI request handling via **ESI Tagged Types**.
111
+ - Deprecated `injectESIRequestBody` in favor of `decoreateESIRequestBody` in later versions.
90
112
 
91
- > Utilized `decoreateESIRequestBody` to generate ESI request API objects with narrowed endpoints by accessing camel-cased "tags".
113
+ Minimal default implementation:
92
114
 
93
115
  ```ts
94
- import * as taggedApi from "eve-esi-types/lib/tagged-request-api.mjs";
95
-
96
- const esiRequest = taggedApi.decoreateESIRequestBody(...);
97
- const ret = await esiRequest.universe.get("/universe/structures/", { query: { filter: "market" }});
116
+ import { esi } from "eve-esi-types/lib/tagged-request-api.mjs";
117
+ const response = await esi.universe.get("/universe/structures/", { query: { filter: "market" } });
98
118
  ```
99
119
 
120
+ ---
100
121
 
101
122
  ## References
102
123
 
103
- - [`ESI Types Utility Definitions`](./docs/v3/esi-types-util3.md)
124
+ - [ESI Types Utility Definitions](./docs/v3/esi-types-util3.md)
125
+ - [ESI Tagged Types Utility Definitions](./docs/esi-tagged-types.md)
126
+
127
+ ---
104
128
 
105
- - [`ESI Tagged Types Utility Definitions`](./docs/esi-tagged-types.md)
129
+ Have questions or issues? Feel free to explore the [GitHub repository](https://github.com/jeffy-g/eve-esi-types) or open an issue!
@@ -9,15 +9,15 @@
9
9
  * THIS DTS IS AUTO GENERATED, DO NOT EDIT
10
10
  *
11
11
  * @file eve-esi-types/v2/esi-tagged-types.d.ts
12
- * @summary This file is auto-generated and defines version 3.2.4 of the EVE Online ESI response types.
12
+ * @summary This file is auto-generated and defines version 3.2.7 of the EVE Online ESI response types.
13
13
  */
14
- import type { TESIResponseOKMap } from "./index.d.ts";
14
+ import type { TESIResponseOKMap, ResolveEndpointParameters } from "./index.d.ts";
15
15
  export type * from "./index.d.ts";
16
16
 
17
17
  /**
18
18
  * Converts a string to lower camel case.
19
19
  *
20
- * @template S - The string to convert.
20
+ * @template S The string to convert.
21
21
  * @example
22
22
  * // returns "assets"
23
23
  * LCamelCase<"Assets">
@@ -46,7 +46,7 @@ declare type InferSomethingBy<Tag, AsType extends InferSomethingByBrand = InferS
46
46
  // - - - - - - - - - - - - - - - - - - - - - - - - - -
47
47
  /**
48
48
  * Maps HTTP methods to their corresponding tags.
49
- * @template M - The HTTP method.
49
+ * @template M The HTTP method.
50
50
  * @date 2025/2/28
51
51
  */
52
52
  export declare type ESITags = InferSomethingBy<never, InferSomethingByTags>;
@@ -61,7 +61,7 @@ export declare type LESITags = LCamelCase<ESITags>;
61
61
  /**
62
62
  * Infers the HTTP method based on the provided tag.
63
63
  *
64
- * @template Tag - The tag to infer the method for.
64
+ * @template Tag The tag to infer the method for.
65
65
  * @date 2025/2/28
66
66
  */
67
67
  export declare type InferMethod<Tag> = InferSomethingBy<Tag>;
@@ -80,16 +80,13 @@ type XPlanetary = InferMethod<"Planetary Interaction">;
80
80
  *
81
81
  * + Customed InferEndpointOrigin
82
82
  *
83
- * @template RealEP - The real endpoint type.
84
- * @template Endpoints - The possible endpoints.
85
- *
86
- * @typeParam RealEP - The type of the real endpoint.
87
- * @typeParam Endpoints - The type of the possible endpoints.
83
+ * @template RealEP The type of the real endpoint.
84
+ * @template Endpoints The type of the possible endpoints.
88
85
  *
89
86
  * @returns The inferred endpoint origin.
90
87
  */
91
88
  type _InferEndpointOrigin<
92
- RealEP extends unknown, Endpoints extends string | number | symbol
89
+ RealEP extends unknown, Endpoints extends PropertyKey
93
90
  > = {
94
91
  [EP in Endpoints]: RealEP extends ReplacePathParams<EP>
95
92
  ? EP : never;
@@ -97,38 +94,75 @@ type _InferEndpointOrigin<
97
94
 
98
95
  /**
99
96
  * Creates a function type for making requests to tagged endpoints.
100
- *
101
- * @template M - The HTTP method.
102
- * @template Tag - The tag associated with the endpoint.
103
- * @template ActualOpt - The actual options for the request.
104
- * @template EndPoints - The possible endpoints.
105
- * @template REP - The real endpoint path.
106
- * @template EPX - The inferred endpoint origin.
107
- * @template PPM - The path parameters.
108
- * @template Opt - The request options.
109
- * @template Ret - The response type.
110
- * @template HasOpt - Indicates if the endpoint has required parameters.
111
- *
112
- * @param endpoint - The endpoint path.
113
- * @param options - An optional object containing additional options for the request. If the endpoint has required parameters, this parameter must be provided.
114
- * @returns A promise that resolves to the response.
115
- *
97
+ *
98
+ * This utility type defines a function signature for interacting with ESI endpoints
99
+ * that are associated with specific tags and HTTP methods. It ensures type safety
100
+ * by inferring the required parameters, options, and response types for the given endpoint.
101
+ *
102
+ * @template M - The HTTP method (e.g., "get", "post").
103
+ * @template Tag - The tag associated with the endpoint (e.g., "Assets", "Skills").
104
+ * @template ActualOpt - A record type representing additional options for the request.
105
+ * @template EndPoints - The possible endpoints associated with the tag and method.
106
+ *
107
+ * @param endpoint - The endpoint path, which can be parameterized or resolved.
108
+ * @param options - An optional object containing additional options for the request.
109
+ * If the endpoint has required parameters, this parameter must be provided.
110
+ * @returns A promise that resolves to the response type of the endpoint.
111
+ *
116
112
  * @remarks
117
- * The `...options: HasOpt extends 1 ? [Opt] : [Opt?]` parameter is defined this way to enforce that if the endpoint has required parameters,
118
- * the `options` parameter must be provided. If there are no required parameters, the `options` parameter is optional.
113
+ * - The `...options: Params["optionIsRequire"] extends 1 ? [Opt] : [Opt?]` parameter ensures
114
+ * that if the endpoint has required parameters, the `options` parameter must be provided.
115
+ * If there are no required parameters, the `options` parameter is optional.
116
+ * - This type leverages `ResolveEndpointParameters` to infer the required options and response type.
117
+ *
118
+ * @example
119
+ * ```ts
120
+ * // Example: Making a request to the "Assets" tag with the "get" method
121
+ * type AssetsRequest = TaggedEndpointRequestFunction2<"get", "Assets", ESIRequestOptions>;
122
+ * const fetchAssets: AssetsRequest = async (endpoint, ...options) => {
123
+ * // Implementation here
124
+ * throw new Error();
125
+ * };
126
+ * fetchAssets("/characters/{character_id}/assets/", {
127
+ * pathParams: 12345,
128
+ * auth: true,
129
+ * token: "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9..."
130
+ * }).then(response => {
131
+ * console.log(response);
132
+ * });
133
+ * ```
134
+ *
135
+ * @see {@link ResolveEndpointParameters}
136
+ * @see {@link SelectEndpointByTag}
137
+ * @see {@link InferESIResponseResult}
119
138
  */
139
+ /* ctt
120
140
  export declare type TaggedEndpointRequestFunction2<
121
141
  M extends TESIEntryMethod, Tag extends ESITags,
122
142
  ActualOpt extends Record<string, unknown> = {},
123
143
  EndPoints extends SelectEndpointByTag<Tag, M> = SelectEndpointByTag<Tag, M>,
124
144
  > = <
125
145
  REP extends ReplacePathParams<EndPoints> | EndPoints,
126
- EPX extends _InferEndpointOrigin<REP, EndPoints> extends never ? REP: _InferEndpointOrigin<REP, EndPoints>,
127
- PPM extends InferPathParams<REP, EPX>,
128
- Opt extends IdentifyParameters<M, EPX, ActualOpt, PPM>,
129
- Ret extends InferESIResponseResult<M, EPX>,
130
- HasOpt = HasRequireParams<M, EPX, PPM>,
146
+ EPO extends _InferEndpointOrigin<REP, EndPoints> extends never ? REP: _InferEndpointOrigin<REP, EndPoints>,
147
+ PPM extends InferPathParams<REP, EPO>,
148
+ Opt extends IdentifyParameters<M, EPO, ActualOpt, PPM>,
149
+ Ret extends InferESIResponseResult<M, EPO>,
150
+ HasOpt = HasRequireParams<M, EPO, PPM>,
131
151
  >(endpoint: REP, ...options: HasOpt extends 1 ? [Opt] : [Opt?]) => Promise<Ret>;
152
+ /*/
153
+ export declare type TaggedEndpointRequestFunction2<
154
+ M extends TESIEntryMethod, Tag extends ESITags,
155
+ ActualOpt extends Record<string, unknown> = {},
156
+ EndPoints extends SelectEndpointByTag<Tag, M> = SelectEndpointByTag<Tag, M>,
157
+ > = <
158
+ REP extends ReplacePathParams<EndPoints> | EndPoints,
159
+ EPO extends _InferEndpointOrigin<REP, EndPoints> extends never ? REP: _InferEndpointOrigin<REP, EndPoints>,
160
+ // @ts-expect-error TODO: 2025/4/28 TS2344: Type 'EPO' does not satisfy the constraint 'ResolvedEndpoint<M, REP>'
161
+ Params extends ResolveEndpointParameters<M, REP, EPO, ActualOpt>,
162
+ Opt extends Params["finalOptions"],
163
+ Ret extends Params["result"],
164
+ >(endpoint: REP, ...options: Params["optionIsRequire"] extends 1 ? [Opt] : [Opt?]) => Promise<Ret>;
165
+ //*/
132
166
 
133
167
 
134
168
  // - - - - - - - - - - - - - - - - - - - - - - - - - -
@@ -137,8 +171,8 @@ export declare type TaggedEndpointRequestFunction2<
137
171
  /**
138
172
  * Maps tags to their corresponding endpoint request functions.
139
173
  *
140
- * @template Tag - The tag to map.
141
- * @template ActualOpt - The actual options for the request.
174
+ * @template Tag The tag to map.
175
+ * @template ActualOpt The actual options for the request.
142
176
  * @date 2025/2/28
143
177
  */
144
178
  export declare type ESITaggedEndpointRequest2<Tag extends ESITags, ActualOpt extends Record<string, unknown> = {}> = {
@@ -153,19 +187,18 @@ export declare type ESITaggedEndpointRequest2<Tag extends ESITags, ActualOpt ext
153
187
  /**
154
188
  * Selects an endpoint by tag and method.
155
189
  *
156
- * @template Tag - The tag associated with the endpoint.
157
- * @template M - The HTTP method.
158
- * @template EP - The endpoint path.
190
+ * @template Tag The tag associated with the endpoint.
191
+ * @template M The HTTP method.
159
192
  * @date 2025/2/28
160
193
  */
161
194
  export declare type SelectEndpointByTag<
162
195
  Tag extends ESITags, M extends TESIEntryMethod
163
196
  > = {
164
- [EP in keyof TESIResponseOKMap[M]]: TESIResponseOKMap[M][EP] extends { tag: infer ActualTag }
197
+ [EP in ESIEndpointOf<M>]: TESIResponseOKMap[M][EP] extends { tag: infer ActualTag }
165
198
  ? ActualTag extends Tag
166
199
  ? EP : never
167
200
  : never;
168
- }[keyof TESIResponseOKMap[M]];
201
+ }[ESIEndpointOf<M>];
169
202
  /* ctt
170
203
  type XAssetsEndpointGet = SelectEndpointByTag<"Assets", "get">;
171
204
  type XAssetsEndpointPost = SelectEndpointByTag<"Assets", "post">;
@@ -175,7 +208,7 @@ type XAssetsEndpointPost = SelectEndpointByTag<"Assets", "post">;
175
208
  /**
176
209
  * Maps lower camel case tags to their corresponding endpoint request functions.
177
210
  *
178
- * @template ActualOpt - The actual options for the request.
211
+ * @template ActualOpt The actual options for the request.
179
212
  * @date 2025/3/12
180
213
  */
181
214
  export declare type TaggedESIRequestMap2<ActualOpt extends Record<string, unknown> = {}> = {
@@ -189,9 +222,9 @@ export declare type TaggedESIRequestMap2<ActualOpt extends Record<string, unknow
189
222
  * const esiRq: TaggedESIRequestMapPartial2<"factionWarfare" | "wallet">;
190
223
  * ```
191
224
  *
192
- * @template Props - The properties to require in the partial map.
225
+ * @template LowerTags The properties to require in the partial map.
193
226
  * @date 2025/2/28
194
227
  */
195
- export declare type TaggedESIRequestMapPartial2<Props extends LCamelCase<ESITags>> = RequireThese<Partial<TaggedESIRequestMap2>, Props>;
228
+ export declare type TaggedESIRequestMapPartial2<LowerTags extends LCamelCase<ESITags>> = RequireThese<Partial<TaggedESIRequestMap2>, LowerTags>;
196
229
 
197
230
  export as namespace XESI;