@archildata/api-types 0.0.75 → 0.0.77
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/index.d.ts +122 -4
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -632,6 +632,26 @@ export interface paths {
|
|
|
632
632
|
patch?: never;
|
|
633
633
|
trace?: never;
|
|
634
634
|
};
|
|
635
|
+
"/api/disks/{id}/prefetch": {
|
|
636
|
+
parameters: {
|
|
637
|
+
query?: never;
|
|
638
|
+
header?: never;
|
|
639
|
+
path?: never;
|
|
640
|
+
cookie?: never;
|
|
641
|
+
};
|
|
642
|
+
get?: never;
|
|
643
|
+
put?: never;
|
|
644
|
+
/**
|
|
645
|
+
* Prefetch file ranges
|
|
646
|
+
* @description Warms byte ranges of files on a disk into Archil's cache, so later reads from any client are served without going to object storage. Each range names one file and an optional offset and length; a file may appear in several ranges. The response reports each range in request order and may arrive before the data is fully fetched. Paths are relative to the disk root. A path that does not exist reports `found: false`; a path that is not a regular file is found but warms nothing. If the disk is not mounted anywhere, prefetching loads it.
|
|
647
|
+
*/
|
|
648
|
+
post: operations["prefetchDisk"];
|
|
649
|
+
delete?: never;
|
|
650
|
+
options?: never;
|
|
651
|
+
head?: never;
|
|
652
|
+
patch?: never;
|
|
653
|
+
trace?: never;
|
|
654
|
+
};
|
|
635
655
|
"/api/disks/{id}/exec": {
|
|
636
656
|
parameters: {
|
|
637
657
|
query?: never;
|
|
@@ -901,9 +921,12 @@ export interface paths {
|
|
|
901
921
|
put?: never;
|
|
902
922
|
/**
|
|
903
923
|
* Create a sandbox process connection
|
|
904
|
-
* @description Returns a short-lived
|
|
905
|
-
*
|
|
906
|
-
*
|
|
924
|
+
* @description Returns a short-lived, single-use credential for one WebSocket to the
|
|
925
|
+
* sandbox process API. Connect to `endpoint`, offering the subprotocols
|
|
926
|
+
* `archil.connect.v1` and `archil.token.<token>`; the server selects
|
|
927
|
+
* `archil.connect.v1`. `url` carries the same token in its query string
|
|
928
|
+
* for older clients. The token opens one WebSocket before `expires_at`;
|
|
929
|
+
* an open WebSocket can remain connected after the token expires.
|
|
907
930
|
*/
|
|
908
931
|
post: operations["createSandboxConnection"];
|
|
909
932
|
delete?: never;
|
|
@@ -2141,8 +2164,15 @@ export interface components {
|
|
|
2141
2164
|
nextCursor?: string;
|
|
2142
2165
|
};
|
|
2143
2166
|
SandboxConnection: {
|
|
2144
|
-
/**
|
|
2167
|
+
/**
|
|
2168
|
+
* Format: uri
|
|
2169
|
+
* @description `endpoint` with the token in its query string. Prefer `endpoint` and `token`, which keep the token out of request-line logs.
|
|
2170
|
+
*/
|
|
2145
2171
|
url: string;
|
|
2172
|
+
/** Format: uri */
|
|
2173
|
+
endpoint: string;
|
|
2174
|
+
/** @description Send as the `Sec-WebSocket-Protocol` value `archil.token.<token>`, alongside `archil.connect.v1`. */
|
|
2175
|
+
token: string;
|
|
2146
2176
|
/** Format: date-time */
|
|
2147
2177
|
expires_at: string;
|
|
2148
2178
|
};
|
|
@@ -2820,6 +2850,54 @@ export interface components {
|
|
|
2820
2850
|
*/
|
|
2821
2851
|
clientId: string;
|
|
2822
2852
|
};
|
|
2853
|
+
PrefetchRequest: {
|
|
2854
|
+
/** @description Byte ranges to warm. A request may name at most 1000. */
|
|
2855
|
+
ranges: components["schemas"]["PrefetchRange"][];
|
|
2856
|
+
};
|
|
2857
|
+
PrefetchRange: {
|
|
2858
|
+
/**
|
|
2859
|
+
* @description File path relative to the disk root.
|
|
2860
|
+
* @example models/weights.bin
|
|
2861
|
+
*/
|
|
2862
|
+
path: string;
|
|
2863
|
+
/**
|
|
2864
|
+
* Format: int64
|
|
2865
|
+
* @description First byte to warm. Defaults to 0.
|
|
2866
|
+
*/
|
|
2867
|
+
offset?: number;
|
|
2868
|
+
/**
|
|
2869
|
+
* Format: int64
|
|
2870
|
+
* @description Bytes to warm from `offset`. Defaults to the end of the file.
|
|
2871
|
+
*/
|
|
2872
|
+
length?: number;
|
|
2873
|
+
};
|
|
2874
|
+
PrefetchRangeResult: {
|
|
2875
|
+
/** @description Whether the path exists. */
|
|
2876
|
+
found: boolean;
|
|
2877
|
+
/**
|
|
2878
|
+
* Format: int64
|
|
2879
|
+
* @description Bytes of the range being warmed, including bytes that were already cached.
|
|
2880
|
+
*/
|
|
2881
|
+
bytesRequested: number;
|
|
2882
|
+
/**
|
|
2883
|
+
* Format: int64
|
|
2884
|
+
* @description Of `bytesRequested`, the bytes fetched (or still being fetched) from object storage.
|
|
2885
|
+
*/
|
|
2886
|
+
bytesWarmed: number;
|
|
2887
|
+
/**
|
|
2888
|
+
* @description Set when this range was not warmed: `retry` for a transient failure worth retrying, `failed` otherwise. Other ranges in the request are unaffected.
|
|
2889
|
+
* @enum {string}
|
|
2890
|
+
*/
|
|
2891
|
+
error?: "retry" | "failed";
|
|
2892
|
+
};
|
|
2893
|
+
ApiResponse_Prefetch: {
|
|
2894
|
+
/** @example true */
|
|
2895
|
+
success: boolean;
|
|
2896
|
+
data: {
|
|
2897
|
+
/** @description One result per requested range, in request order. */
|
|
2898
|
+
results: components["schemas"]["PrefetchRangeResult"][];
|
|
2899
|
+
};
|
|
2900
|
+
};
|
|
2823
2901
|
CreateApiTokenRequest: {
|
|
2824
2902
|
/** @description Token name */
|
|
2825
2903
|
name: string;
|
|
@@ -4657,6 +4735,46 @@ export interface operations {
|
|
|
4657
4735
|
500: components["responses"]["InternalError"];
|
|
4658
4736
|
};
|
|
4659
4737
|
};
|
|
4738
|
+
prefetchDisk: {
|
|
4739
|
+
parameters: {
|
|
4740
|
+
query?: never;
|
|
4741
|
+
header?: never;
|
|
4742
|
+
path: {
|
|
4743
|
+
/** @description Disk ID (format `dsk-{16 hex chars}`) */
|
|
4744
|
+
id: components["parameters"]["DiskId"];
|
|
4745
|
+
};
|
|
4746
|
+
cookie?: never;
|
|
4747
|
+
};
|
|
4748
|
+
requestBody: {
|
|
4749
|
+
content: {
|
|
4750
|
+
"application/json": components["schemas"]["PrefetchRequest"];
|
|
4751
|
+
};
|
|
4752
|
+
};
|
|
4753
|
+
responses: {
|
|
4754
|
+
/** @description Per-range prefetch results */
|
|
4755
|
+
200: {
|
|
4756
|
+
headers: {
|
|
4757
|
+
[name: string]: unknown;
|
|
4758
|
+
};
|
|
4759
|
+
content: {
|
|
4760
|
+
"application/json": components["schemas"]["ApiResponse_Prefetch"];
|
|
4761
|
+
};
|
|
4762
|
+
};
|
|
4763
|
+
400: components["responses"]["ValidationError"];
|
|
4764
|
+
401: components["responses"]["Unauthorized"];
|
|
4765
|
+
404: components["responses"]["NotFound"];
|
|
4766
|
+
500: components["responses"]["InternalError"];
|
|
4767
|
+
/** @description Temporarily unavailable; safe to retry. */
|
|
4768
|
+
503: {
|
|
4769
|
+
headers: {
|
|
4770
|
+
[name: string]: unknown;
|
|
4771
|
+
};
|
|
4772
|
+
content: {
|
|
4773
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
4774
|
+
};
|
|
4775
|
+
};
|
|
4776
|
+
};
|
|
4777
|
+
};
|
|
4660
4778
|
execDisk: {
|
|
4661
4779
|
parameters: {
|
|
4662
4780
|
query?: never;
|