zlient 2.1.11 → 3.0.2
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/README.md +98 -28
- package/dist/endpoint/base-endpoint.d.ts +12 -11
- package/dist/endpoint/base-endpoint.d.ts.map +1 -1
- package/dist/http/http-client.d.ts +26 -5
- package/dist/http/http-client.d.ts.map +1 -1
- package/dist/index.cjs +122 -199
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +118 -169
- package/dist/index.js.map +1 -1
- package/dist/types.d.ts +58 -15
- package/dist/types.d.ts.map +1 -1
- package/dist/validation.d.ts +35 -16
- package/dist/validation.d.ts.map +1 -1
- package/package.json +15 -13
- package/dist/schemas/common.d.ts +0 -88
- package/dist/schemas/common.d.ts.map +0 -1
package/README.md
CHANGED
|
@@ -6,28 +6,36 @@
|
|
|
6
6
|

|
|
7
7
|

|
|
8
8
|
|
|
9
|
-
Build robust, type-safe API clients with
|
|
9
|
+
Build robust, type-safe API clients with runtime validation, retry logic, and zero boilerplate. Use **any** [Standard Schema](https://standardschema.dev) library — Zod, Valibot, ArkType, and more.
|
|
10
10
|
|
|
11
11
|
## Features
|
|
12
12
|
|
|
13
|
-
-
|
|
14
|
-
-
|
|
15
|
-
-
|
|
16
|
-
-
|
|
17
|
-
-
|
|
18
|
-
-
|
|
13
|
+
- **Standard Schema**: Use Zod, Valibot, ArkType, or any compatible validator. No lock-in.
|
|
14
|
+
- **Functional API**: Define endpoints with pure functions and automatic type inference.
|
|
15
|
+
- **Type-Safe**: Full TypeScript support. Arguments and responses are strictly typed.
|
|
16
|
+
- **Runtime Validation**: Validate requests, responses, query params, and path params.
|
|
17
|
+
- **Resilience**: Built-in exponential backoff retries and timeouts.
|
|
18
|
+
- **Auth**: Logic-safe authentication providers (Bearer, API Key, Custom).
|
|
19
|
+
- **Observability**: Hooks for structured logging and metrics.
|
|
19
20
|
|
|
20
21
|
---
|
|
21
22
|
|
|
22
23
|
## Installation
|
|
23
24
|
|
|
24
25
|
```bash
|
|
25
|
-
npm install zlient
|
|
26
|
+
npm install zlient
|
|
26
27
|
# or
|
|
27
|
-
bun add zlient
|
|
28
|
+
bun add zlient
|
|
28
29
|
```
|
|
29
30
|
|
|
30
|
-
|
|
31
|
+
Then install your preferred validation library:
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
# Pick one (or more!)
|
|
35
|
+
npm install zod # Zod
|
|
36
|
+
npm install valibot # Valibot
|
|
37
|
+
npm install arktype # ArkType
|
|
38
|
+
```
|
|
31
39
|
|
|
32
40
|
---
|
|
33
41
|
|
|
@@ -48,15 +56,16 @@ const client = new HttpClient({
|
|
|
48
56
|
|
|
49
57
|
### 2. Define Endpoint
|
|
50
58
|
|
|
51
|
-
Use `createEndpoint`
|
|
59
|
+
Use `createEndpoint` with your favorite schema library:
|
|
52
60
|
|
|
61
|
+
<!-- tabs:start -->
|
|
62
|
+
#### **Zod**
|
|
53
63
|
```typescript
|
|
54
64
|
import { z } from 'zod';
|
|
55
65
|
|
|
56
66
|
const getUser = client.createEndpoint({
|
|
57
67
|
method: 'GET',
|
|
58
68
|
path: (params) => `/users/${params.id}`,
|
|
59
|
-
// Strict schemas for all inputs
|
|
60
69
|
pathParams: z.object({ id: z.string() }),
|
|
61
70
|
response: z.object({
|
|
62
71
|
id: z.string(),
|
|
@@ -66,6 +75,39 @@ const getUser = client.createEndpoint({
|
|
|
66
75
|
});
|
|
67
76
|
```
|
|
68
77
|
|
|
78
|
+
#### **Valibot**
|
|
79
|
+
```typescript
|
|
80
|
+
import * as v from 'valibot';
|
|
81
|
+
|
|
82
|
+
const getUser = client.createEndpoint({
|
|
83
|
+
method: 'GET',
|
|
84
|
+
path: (params) => `/users/${params.id}`,
|
|
85
|
+
pathParams: v.object({ id: v.string() }),
|
|
86
|
+
response: v.object({
|
|
87
|
+
id: v.string(),
|
|
88
|
+
name: v.string(),
|
|
89
|
+
email: v.pipe(v.string(), v.email()),
|
|
90
|
+
}),
|
|
91
|
+
});
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
#### **ArkType**
|
|
95
|
+
```typescript
|
|
96
|
+
import { type } from 'arktype';
|
|
97
|
+
|
|
98
|
+
const getUser = client.createEndpoint({
|
|
99
|
+
method: 'GET',
|
|
100
|
+
path: (params) => `/users/${params.id}`,
|
|
101
|
+
pathParams: type({ id: 'string' }),
|
|
102
|
+
response: type({
|
|
103
|
+
id: 'string',
|
|
104
|
+
name: 'string',
|
|
105
|
+
email: 'string.email',
|
|
106
|
+
}),
|
|
107
|
+
});
|
|
108
|
+
```
|
|
109
|
+
<!-- tabs:end -->
|
|
110
|
+
|
|
69
111
|
### 3. Call It
|
|
70
112
|
|
|
71
113
|
TypeScript will enforce inputs and infer the response type automatically.
|
|
@@ -104,6 +146,8 @@ client.setAuth(new ApiKeyAuth({ header: 'X-API-KEY', value: 'secret' }));
|
|
|
104
146
|
Handle different responses for different status codes.
|
|
105
147
|
|
|
106
148
|
```typescript
|
|
149
|
+
import { z } from 'zod';
|
|
150
|
+
|
|
107
151
|
const createPost = client.createEndpoint({
|
|
108
152
|
method: 'POST',
|
|
109
153
|
path: '/posts',
|
|
@@ -118,40 +162,46 @@ const result = await createPost({ data: { title: 'Hello' } });
|
|
|
118
162
|
// `result` type is the union of the 201 and 400 schemas
|
|
119
163
|
```
|
|
120
164
|
|
|
165
|
+
### Error Handling
|
|
166
|
+
|
|
167
|
+
Validation errors are thrown as `ApiError` with detailed issues:
|
|
168
|
+
|
|
169
|
+
```typescript
|
|
170
|
+
import { ApiError } from 'zlient';
|
|
171
|
+
|
|
172
|
+
try {
|
|
173
|
+
await getUser({ pathParams: { id: '123' } });
|
|
174
|
+
} catch (error) {
|
|
175
|
+
if (error instanceof ApiError && error.validationIssues) {
|
|
176
|
+
// Handle validation error
|
|
177
|
+
console.log(error.validationIssues);
|
|
178
|
+
// [{ message: 'Expected string, got number', path: ['id'] }]
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
```
|
|
182
|
+
|
|
121
183
|
### FormData Support
|
|
122
184
|
|
|
123
|
-
Upload files and send multipart form data seamlessly.
|
|
185
|
+
Upload files and send multipart form data seamlessly.
|
|
124
186
|
|
|
125
187
|
```typescript
|
|
126
|
-
|
|
188
|
+
import { z } from 'zod';
|
|
189
|
+
|
|
127
190
|
const uploadFile = client.createEndpoint({
|
|
128
191
|
method: 'POST',
|
|
129
192
|
path: '/upload',
|
|
130
193
|
response: z.object({ fileId: z.string(), url: z.string() }),
|
|
131
194
|
advanced: {
|
|
132
|
-
skipRequestValidation: true, // FormData can't be validated
|
|
195
|
+
skipRequestValidation: true, // FormData can't be validated
|
|
133
196
|
},
|
|
134
197
|
});
|
|
135
198
|
|
|
136
199
|
const formData = new FormData();
|
|
137
200
|
formData.append('file', fileBlob, 'document.pdf');
|
|
138
|
-
formData.append('description', 'My document');
|
|
139
201
|
|
|
140
202
|
const result = await uploadFile({ data: formData });
|
|
141
|
-
console.log(result.url);
|
|
142
|
-
```
|
|
143
|
-
|
|
144
|
-
You can also use the low-level `request` method directly:
|
|
145
|
-
|
|
146
|
-
```typescript
|
|
147
|
-
const formData = new FormData();
|
|
148
|
-
formData.append('avatar', imageFile);
|
|
149
|
-
|
|
150
|
-
const { data } = await client.post('/users/avatar', formData);
|
|
151
203
|
```
|
|
152
204
|
|
|
153
|
-
> **Note**: When using `FormData`, the `Content-Type` header is automatically removed so the browser can set it with the proper multipart boundary.
|
|
154
|
-
|
|
155
205
|
### Metrics & Logging
|
|
156
206
|
|
|
157
207
|
Integrate with any monitoring stack (Datadog, Prometheus, etc.).
|
|
@@ -168,6 +218,26 @@ const client = new HttpClient({
|
|
|
168
218
|
|
|
169
219
|
---
|
|
170
220
|
|
|
221
|
+
## Migration from v2
|
|
222
|
+
|
|
223
|
+
v3 introduces Standard Schema support. Key changes:
|
|
224
|
+
|
|
225
|
+
```diff
|
|
226
|
+
- import { z } from 'zod'; // Required peer dependency
|
|
227
|
+
+ // Use any Standard Schema library (Zod, Valibot, ArkType)
|
|
228
|
+
|
|
229
|
+
- catch (e) { if (e instanceof ZodError) { ... } }
|
|
230
|
+
+ catch (e) { if (e instanceof ApiError && e.validationIssues) { ... } }
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
---
|
|
234
|
+
|
|
235
|
+
## Documentation
|
|
236
|
+
|
|
237
|
+
📖 [Full Documentation](https://zlient.dev)
|
|
238
|
+
|
|
239
|
+
---
|
|
240
|
+
|
|
171
241
|
## License
|
|
172
242
|
|
|
173
243
|
MIT © [Emirhan Gumus](https://github.com/emirhangumus)
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
1
|
import { HttpClient } from '../http/http-client';
|
|
3
|
-
import { HTTPMethod } from '../types';
|
|
4
|
-
export type EndpointConfig<ResSchema extends
|
|
2
|
+
import { HTTPMethod, ResponseSchema, SchemaMap, StandardSchemaV1 } from '../types';
|
|
3
|
+
export type EndpointConfig<ResSchema extends ResponseSchema, ReqSchema extends StandardSchemaV1 | undefined = undefined, QuerySchema extends StandardSchemaV1 | undefined = undefined, PathSchema extends StandardSchemaV1 | undefined = undefined, MustHeaderKeys extends readonly string[] = readonly []> = {
|
|
5
4
|
method: keyof typeof HTTPMethod;
|
|
6
|
-
path: string | ((params:
|
|
5
|
+
path: string | ((params: StandardSchemaV1.InferOutput<Exclude<PathSchema, undefined>>) => string);
|
|
7
6
|
response: ResSchema;
|
|
8
7
|
request?: ReqSchema;
|
|
9
8
|
query?: QuerySchema;
|
|
@@ -21,19 +20,21 @@ export type EndpointConfig<ResSchema extends z.ZodType | Record<number, z.ZodTyp
|
|
|
21
20
|
type RequiredHeaders<Keys extends readonly string[]> = Keys extends readonly [] ? Record<string, string> | undefined : {
|
|
22
21
|
[K in Keys[number]]: string;
|
|
23
22
|
} & Record<string, string>;
|
|
24
|
-
export type EndpointCallParams<ReqSchema extends
|
|
25
|
-
data?: ReqSchema extends
|
|
26
|
-
query?: QuerySchema extends
|
|
27
|
-
pathParams?: PathSchema extends
|
|
23
|
+
export type EndpointCallParams<ReqSchema extends StandardSchemaV1 | undefined, QuerySchema extends StandardSchemaV1 | undefined, PathSchema extends StandardSchemaV1 | undefined, MustHeaderKeys extends readonly string[] = readonly []> = {
|
|
24
|
+
data?: ReqSchema extends StandardSchemaV1 ? StandardSchemaV1.InferInput<ReqSchema> : never;
|
|
25
|
+
query?: QuerySchema extends StandardSchemaV1 ? StandardSchemaV1.InferInput<QuerySchema> : never;
|
|
26
|
+
pathParams?: PathSchema extends StandardSchemaV1 ? StandardSchemaV1.InferInput<PathSchema> : never;
|
|
28
27
|
signal?: globalThis.AbortSignal;
|
|
29
28
|
} & (MustHeaderKeys extends readonly [] ? {
|
|
30
29
|
headers?: Record<string, string>;
|
|
31
30
|
} : {
|
|
32
31
|
headers: RequiredHeaders<MustHeaderKeys>;
|
|
33
32
|
});
|
|
34
|
-
type InferResponse<S> = S extends
|
|
35
|
-
|
|
36
|
-
|
|
33
|
+
type InferResponse<S> = S extends StandardSchemaV1 ? StandardSchemaV1.InferOutput<S> : S extends SchemaMap ? {
|
|
34
|
+
[K in keyof S]: S[K] extends StandardSchemaV1 ? StandardSchemaV1.InferOutput<S[K]> : never;
|
|
35
|
+
}[keyof S] : never;
|
|
36
|
+
export type EndpointCall<ResSchema extends ResponseSchema, ReqSchema extends StandardSchemaV1 | undefined, QuerySchema extends StandardSchemaV1 | undefined, PathSchema extends StandardSchemaV1 | undefined, MustHeaderKeys extends readonly string[] = readonly []> = (params: EndpointCallParams<ReqSchema, QuerySchema, PathSchema, MustHeaderKeys>) => Promise<InferResponse<ResSchema>>;
|
|
37
|
+
export declare class EndpointImpl<ResSchema extends ResponseSchema, ReqSchema extends StandardSchemaV1 | undefined, QuerySchema extends StandardSchemaV1 | undefined, PathSchema extends StandardSchemaV1 | undefined, MustHeaderKeys extends readonly string[] = readonly []> {
|
|
37
38
|
private client;
|
|
38
39
|
private config;
|
|
39
40
|
constructor(client: HttpClient, config: EndpointConfig<ResSchema, ReqSchema, QuerySchema, PathSchema, MustHeaderKeys>);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-endpoint.d.ts","sourceRoot":"","sources":["../../lib/endpoint/base-endpoint.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"base-endpoint.d.ts","sourceRoot":"","sources":["../../lib/endpoint/base-endpoint.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EACH,UAAU,EACV,cAAc,EAEd,SAAS,EACT,gBAAgB,EACnB,MAAM,UAAU,CAAC;AAGlB,MAAM,MAAM,cAAc,CACxB,SAAS,SAAS,cAAc,EAChC,SAAS,SAAS,gBAAgB,GAAG,SAAS,GAAG,SAAS,EAC1D,WAAW,SAAS,gBAAgB,GAAG,SAAS,GAAG,SAAS,EAC5D,UAAU,SAAS,gBAAgB,GAAG,SAAS,GAAG,SAAS,EAC3D,cAAc,SAAS,SAAS,MAAM,EAAE,GAAG,SAAS,EAAE,IACpD;IACF,MAAM,EAAE,MAAM,OAAO,UAAU,CAAC;IAChC,IAAI,EAAE,MAAM,GAAG,CAAC,CAAC,MAAM,EAAE,gBAAgB,CAAC,WAAW,CAAC,OAAO,CAAC,UAAU,EAAE,SAAS,CAAC,CAAC,KAAK,MAAM,CAAC,CAAC;IAClG,QAAQ,EAAE,SAAS,CAAC;IACpB,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,QAAQ,CAAC,EAAE;QACT,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;QACnB,qBAAqB,CAAC,EAAE,OAAO,CAAC;QAChC,sBAAsB,CAAC,EAAE,OAA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Config } from '../endpoint/base-endpoint';
|
|
4
|
-
import { ClientOptions, HTTPMethod, HTTPStatusCodeNumber, RequestOptions } from '../types';
|
|
3
|
+
import { ClientOptions, HTTPMethod, HTTPStatusCodeNumber, RequestOptions, ResponseSchema, StandardSchemaV1 } from '../types';
|
|
5
4
|
/**
|
|
6
5
|
* HTTP client with built-in retry logic, authentication, and interceptors.
|
|
7
6
|
* Supports multiple base URLs, type-safe requests, and comprehensive error handling.
|
|
@@ -164,10 +163,32 @@ export declare class HttpClient {
|
|
|
164
163
|
}>;
|
|
165
164
|
/**
|
|
166
165
|
* Create a strongly-typed endpoint builder.
|
|
166
|
+
* Works with any Standard Schema-compatible library (Zod, Valibot, ArkType, etc.)
|
|
167
167
|
*
|
|
168
|
-
* @param config - Endpoint configuration
|
|
169
|
-
* @returns Endpoint
|
|
168
|
+
* @param config - Endpoint configuration with schemas
|
|
169
|
+
* @returns Endpoint call function
|
|
170
|
+
*
|
|
171
|
+
* @example
|
|
172
|
+
* ```ts
|
|
173
|
+
* // With Zod
|
|
174
|
+
* import { z } from 'zod';
|
|
175
|
+
* const getUser = client.createEndpoint({
|
|
176
|
+
* method: 'GET',
|
|
177
|
+
* path: '/users/:id',
|
|
178
|
+
* response: z.object({ id: z.string(), name: z.string() }),
|
|
179
|
+
* pathParams: z.object({ id: z.string() }),
|
|
180
|
+
* });
|
|
181
|
+
*
|
|
182
|
+
* // With Valibot
|
|
183
|
+
* import * as v from 'valibot';
|
|
184
|
+
* const getUser = client.createEndpoint({
|
|
185
|
+
* method: 'GET',
|
|
186
|
+
* path: '/users/:id',
|
|
187
|
+
* response: v.object({ id: v.string(), name: v.string() }),
|
|
188
|
+
* pathParams: v.object({ id: v.string() }),
|
|
189
|
+
* });
|
|
190
|
+
* ```
|
|
170
191
|
*/
|
|
171
|
-
createEndpoint<ResSchema extends
|
|
192
|
+
createEndpoint<ResSchema extends ResponseSchema, ReqSchema extends StandardSchemaV1 | undefined = undefined, QuerySchema extends StandardSchemaV1 | undefined = undefined, PathSchema extends StandardSchemaV1 | undefined = undefined, MustHeaderKeys extends readonly string[] = readonly []>(config: EndpointConfig<ResSchema, ReqSchema, QuerySchema, PathSchema, MustHeaderKeys>): EndpointCall<ResSchema, ReqSchema, QuerySchema, PathSchema, MustHeaderKeys>;
|
|
172
193
|
}
|
|
173
194
|
//# sourceMappingURL=http-client.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http-client.d.ts","sourceRoot":"","sources":["../../lib/http/http-client.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"http-client.d.ts","sourceRoot":"","sources":["../../lib/http/http-client.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAE5C,OAAO,EAAE,YAAY,EAAE,cAAc,EAAgB,MAAM,2BAA2B,CAAC;AAGvF,OAAO,EAEH,aAAa,EAEb,UAAU,EAGV,oBAAoB,EAEpB,cAAc,EACd,cAAc,EAEd,gBAAgB,EAEnB,MAAM,UAAU,CAAC;AAElB;;;;;;;;;;;;;;;GAeG;AACH,qBAAa,UAAU;IACrB,OAAO,CAAC,SAAS,CAAY;IAC7B,OAAO,CAAC,QAAQ,CAA4B;IAC5C,OAAO,CAAC,OAAO,CAAyB;IACxC,OAAO,CAAC,YAAY,CAAe;IACnC,OAAO,CAAC,KAAK,CAAgB;IAC7B,OAAO,CAAC,SAAS,CAAC,CAAS;IAC3B,OAAO,CAAC,IAAI,CAAe;IAC3B,OAAO,CAAC,MAAM,CAAa;IAC3B,OAAO,CAAC,OAAO,CAAmB;IAClC,OAAO,CAAC,iBAAiB,CAAC,CAAqD;IAE/E;;;;;OAKG;gBACS,IAAI,EAAE,aAAa;IAuD/B;;;;;;;;OAQG;IACH,OAAO,CAAC,IAAI,EAAE,YAAY;IAI1B,OAAO,CAAC,cAAc;IAUtB;;;OAGG;IACH,OAAO,CAAC,KAAK;IAIb;;;OAGG;YACW,SAA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