@structbuild/sdk 0.1.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/dist/http.d.ts ADDED
@@ -0,0 +1,18 @@
1
+ import type { HttpClientConfig, HttpResponse, RequestOptions } from "./types/http.js";
2
+ export declare class HttpClient {
3
+ private readonly baseUrl;
4
+ private readonly defaultHeaders;
5
+ private readonly timeout;
6
+ private readonly retry;
7
+ private readonly onRequest;
8
+ private readonly onResponse;
9
+ constructor(config: HttpClientConfig);
10
+ get<T>(path: string, options?: RequestOptions): Promise<HttpResponse<T>>;
11
+ private request;
12
+ private executeRequest;
13
+ private shouldRetry;
14
+ private parseApiResponse;
15
+ private parseRetryAfter;
16
+ private sleep;
17
+ private buildUrl;
18
+ }