@archildata/api-types 0.0.76 → 0.0.78

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 (2) hide show
  1. package/index.d.ts +47 -11
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -516,6 +516,10 @@ export interface paths {
516
516
  * @description Adds an authorized user to a disk. Users can authenticate via:
517
517
  * - **token**: A shared token with a nickname and 4-character suffix
518
518
  * - **awssts**: AWS STS role assumption with an IAM principal ARN
519
+ * - **s3**: An S3 access key pair for the disk's S3-compatible endpoint.
520
+ * The server generates both keys; the secret key is returned only in
521
+ * this response. The credential covers the whole disk, so keep it on
522
+ * your server and hand clients presigned URLs instead of the keys.
519
523
  */
520
524
  post: operations["addDiskUser"];
521
525
  delete?: never;
@@ -921,9 +925,12 @@ export interface paths {
921
925
  put?: never;
922
926
  /**
923
927
  * Create a sandbox process connection
924
- * @description Returns a short-lived WebSocket URL used by the sandbox process API.
925
- * The URL contains a signed token that expires at `expires_at`; an open
926
- * WebSocket can remain connected after the token expires.
928
+ * @description Returns a short-lived, single-use credential for one WebSocket to the
929
+ * sandbox process API. Connect to `endpoint`, offering the subprotocols
930
+ * `archil.connect.v1` and `archil.token.<token>`; the server selects
931
+ * `archil.connect.v1`. `url` carries the same token in its query string
932
+ * for older clients. The token opens one WebSocket before `expires_at`;
933
+ * an open WebSocket can remain connected after the token expires.
927
934
  */
928
935
  post: operations["createSandboxConnection"];
929
936
  delete?: never;
@@ -2161,8 +2168,15 @@ export interface components {
2161
2168
  nextCursor?: string;
2162
2169
  };
2163
2170
  SandboxConnection: {
2164
- /** Format: uri */
2171
+ /**
2172
+ * Format: uri
2173
+ * @description `endpoint` with the token in its query string. Prefer `endpoint` and `token`, which keep the token out of request-line logs.
2174
+ */
2165
2175
  url: string;
2176
+ /** Format: uri */
2177
+ endpoint: string;
2178
+ /** @description Send as the `Sec-WebSocket-Protocol` value `archil.token.<token>`, alongside `archil.connect.v1`. */
2179
+ token: string;
2166
2180
  /** Format: date-time */
2167
2181
  expires_at: string;
2168
2182
  };
@@ -2564,7 +2578,25 @@ export interface components {
2564
2578
  /** @description When true, the credential grants read-only access. Mounts authenticated with this credential reject writes with EROFS. */
2565
2579
  readOnly?: boolean;
2566
2580
  };
2567
- DiskUser: components["schemas"]["TokenUser"] | components["schemas"]["AwsStsUser"];
2581
+ /** @description S3 access key pair for the disk's S3-compatible endpoint. Both keys are generated by the server. The credential grants access to every object on the disk; there is no per-prefix scoping, so do not expose the keys to browsers or other untrusted clients. Sign presigned URLs with them server-side instead. */
2582
+ S3User: {
2583
+ /**
2584
+ * @description discriminator enum property added by openapi-typescript
2585
+ * @enum {string}
2586
+ */
2587
+ type: "s3";
2588
+ nickname?: string;
2589
+ /** @description Optional time-to-live as a Go duration string (e.g. "1h", "30m"). Maximum 365 days ("8760h"). Requests signed with an expired key, including presigned URLs, are rejected. Mutually exclusive with expiresAt. */
2590
+ ttl?: string;
2591
+ /**
2592
+ * Format: date-time
2593
+ * @description Optional absolute expiration time as an RFC3339 timestamp. Must be in the future. Mutually exclusive with ttl.
2594
+ */
2595
+ expiresAt?: string;
2596
+ /** @description When true, the credential may only issue GET and HEAD requests. Writes, deletes, and multipart operations are rejected with AccessDenied. */
2597
+ readOnly?: boolean;
2598
+ };
2599
+ DiskUser: components["schemas"]["TokenUser"] | components["schemas"]["AwsStsUser"] | components["schemas"]["S3User"];
2568
2600
  DiskResponse: {
2569
2601
  /**
2570
2602
  * @description Disk ID
@@ -2700,7 +2732,7 @@ export interface components {
2700
2732
  };
2701
2733
  AuthorizedUser: {
2702
2734
  /** @enum {string} */
2703
- type?: "token" | "awssts";
2735
+ type?: "token" | "awssts" | "s3";
2704
2736
  /**
2705
2737
  * @deprecated
2706
2738
  * @description Use identifier instead. Only populated for awssts type (the IAM ARN).
@@ -2710,7 +2742,11 @@ export interface components {
2710
2742
  tokenSuffix?: string;
2711
2743
  /** @description The generated mount token. Only present in the response when the server generates the token (i.e. principal was not provided). This value is shown exactly once and cannot be retrieved again. */
2712
2744
  token?: string;
2713
- /** @description Stable identifier for this user, returned in creation and list responses. Use this value with DELETE /api/disks/{id}/users/{type}?identifier={identifier} to remove the user. For awssts users, this is the IAM ARN. */
2745
+ /** @description The S3 access key ID. Only present for s3 users. */
2746
+ s3AccessKeyId?: string;
2747
+ /** @description The generated S3 secret access key. Only present in the creation response for s3 users. This value is shown exactly once and cannot be retrieved again. */
2748
+ s3SecretKey?: string;
2749
+ /** @description Stable identifier for this user, returned in creation and list responses. Use this value with DELETE /api/disks/{id}/users/{type}?identifier={identifier} to remove the user. For awssts users, this is the IAM ARN; for s3 users, the access key ID. */
2714
2750
  identifier?: string;
2715
2751
  /** Format: date-time */
2716
2752
  createdAt?: string;
@@ -2729,10 +2765,10 @@ export interface components {
2729
2765
  /** @description Whether this token grants read-only access. */
2730
2766
  readOnly?: boolean;
2731
2767
  /**
2732
- * @description Current lifecycle status of the token.
2768
+ * @description Current lifecycle status of the token. `in_use` means a one-use token is being consumed by a mount that is still in progress.
2733
2769
  * @enum {string}
2734
2770
  */
2735
- status?: "active" | "expired" | "consumed";
2771
+ status?: "active" | "expired" | "consumed" | "in_use";
2736
2772
  };
2737
2773
  /** @description All API responses use a standard envelope with `success: boolean` and `data` (on success) or `error: string` (on failure). The ApiResponse_* schemas each define the specific `data` shape for their endpoint. */
2738
2774
  ApiResponse_DiskList: {
@@ -4506,7 +4542,7 @@ export interface operations {
4506
4542
  removeDiskUser: {
4507
4543
  parameters: {
4508
4544
  query?: {
4509
- /** @description Identifier of the user to remove, as returned in the creation or list response. For awssts users, this is the IAM ARN. */
4545
+ /** @description Identifier of the user to remove, as returned in the creation or list response. For awssts users, this is the IAM ARN; for s3 users, the access key ID. */
4510
4546
  identifier?: string;
4511
4547
  /**
4512
4548
  * @deprecated
@@ -4519,7 +4555,7 @@ export interface operations {
4519
4555
  /** @description Disk ID (format `dsk-{16 hex chars}`) */
4520
4556
  id: components["parameters"]["DiskId"];
4521
4557
  /** @description The type of user authentication */
4522
- userType: "token" | "awssts";
4558
+ userType: "token" | "awssts" | "s3";
4523
4559
  };
4524
4560
  cookie?: never;
4525
4561
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@archildata/api-types",
3
- "version": "0.0.76",
3
+ "version": "0.0.78",
4
4
  "description": "API types for the Archil control plane",
5
5
  "type": "module",
6
6
  "types": "index.d.ts",