@archildata/api-types 0.0.38 → 0.0.40

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 +225 -0
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -459,6 +459,59 @@ export interface paths {
459
459
  patch?: never;
460
460
  trace?: never;
461
461
  };
462
+ "/api/sandboxes/{sid}/port-tokens": {
463
+ parameters: {
464
+ query?: never;
465
+ header?: never;
466
+ path?: never;
467
+ cookie?: never;
468
+ };
469
+ /**
470
+ * List sandbox port tokens
471
+ * @description Lists unexpired private port token metadata without returning raw tokens.
472
+ */
473
+ get: operations["listSandboxPortTokens"];
474
+ put?: never;
475
+ /**
476
+ * Create a private sandbox port token
477
+ * @description Creates token-authorized HTTP access to one port. Send the raw token returned
478
+ * by this request in the `X-Archil-Token` request header at the stable
479
+ * `<port>-<sandbox-route-id>.<zone>` hostname. Public ports accept connections
480
+ * without a token; otherwise a valid token for that sandbox and port is required.
481
+ * The token is not returned again.
482
+ */
483
+ post: operations["createSandboxPortToken"];
484
+ delete?: never;
485
+ options?: never;
486
+ head?: never;
487
+ patch?: never;
488
+ trace?: never;
489
+ };
490
+ "/api/sandboxes/{sid}/port-tokens/{token_id}": {
491
+ parameters: {
492
+ query?: never;
493
+ header?: never;
494
+ path?: never;
495
+ cookie?: never;
496
+ };
497
+ /**
498
+ * Get a sandbox port token
499
+ * @description Returns token metadata without its raw token. Expired tokens return not found.
500
+ */
501
+ get: operations["getSandboxPortToken"];
502
+ put?: never;
503
+ post?: never;
504
+ /**
505
+ * Revoke a sandbox port token
506
+ * @description New private connections using the token fail after this request
507
+ * completes; established connections remain open. Expired tokens return not found.
508
+ */
509
+ delete: operations["deleteSandboxPortToken"];
510
+ options?: never;
511
+ head?: never;
512
+ patch?: never;
513
+ trace?: never;
514
+ };
462
515
  "/api/sandboxes/{sid}/pause": {
463
516
  parameters: {
464
517
  query?: never;
@@ -763,6 +816,11 @@ export interface components {
763
816
  platform?: "arm64" | "amd64";
764
817
  /** @description Public hostnames published by enabled sandbox services. */
765
818
  endpoints?: components["schemas"]["SandboxEndpoint"][];
819
+ /**
820
+ * @description Whether services inside the sandbox can expose ingress. Explicit API port exposure remains available regardless of this setting.
821
+ * @default false
822
+ */
823
+ enable_service_ingress: boolean;
766
824
  /** Format: date-time */
767
825
  created_at: string;
768
826
  /** Format: date-time */
@@ -801,6 +859,53 @@ export interface components {
801
859
  success: boolean;
802
860
  data: components["schemas"]["SandboxPortList"];
803
861
  };
862
+ SandboxPortToken: {
863
+ /** @description Stable token identifier used for get and revoke operations. */
864
+ id: string;
865
+ port: number;
866
+ /** Format: date-time */
867
+ created_at: string;
868
+ /**
869
+ * Format: date-time
870
+ * @description When the token expires. Absent for a non-expiring token.
871
+ */
872
+ expires_at?: string;
873
+ };
874
+ CreatedSandboxPortToken: components["schemas"]["SandboxPortToken"] & {
875
+ /** @description Stable sandbox port hostname, shared with public access. */
876
+ hostname: string;
877
+ /** @description Raw token returned only when the token is created. */
878
+ token: string;
879
+ };
880
+ CreateSandboxPortTokenRequest: {
881
+ port: number;
882
+ /**
883
+ * @description Token lifetime as a Go duration string (for example, "4m", "1h",
884
+ * or "24h"). Maximum 365 days ("8760h"). Omit for no expiration.
885
+ * @example 4m
886
+ */
887
+ ttl?: string;
888
+ };
889
+ SandboxPortTokenList: {
890
+ tokens: components["schemas"]["SandboxPortToken"][];
891
+ };
892
+ ApiResponse_CreatedSandboxPortToken: {
893
+ /** @example true */
894
+ success: boolean;
895
+ data: components["schemas"]["CreatedSandboxPortToken"];
896
+ };
897
+ ApiResponse_SandboxPortToken: {
898
+ /** @example true */
899
+ success: boolean;
900
+ data: components["schemas"]["SandboxPortToken"];
901
+ };
902
+ ApiResponse_SandboxPortTokenList: {
903
+ /** @example true */
904
+ success: boolean;
905
+ data: components["schemas"]["SandboxPortTokenList"];
906
+ /** @description Set when more port tokens remain. */
907
+ nextCursor?: string;
908
+ };
804
909
  SandboxConnection: {
805
910
  /** Format: uri */
806
911
  url: string;
@@ -836,6 +941,11 @@ export interface components {
836
941
  base_image: string;
837
942
  /** @description TCP ports to expose publicly when the sandbox is created. */
838
943
  ports?: number[];
944
+ /**
945
+ * @description Allow services inside the sandbox to expose ingress. When false, services still run but their ports must be exposed explicitly through the API. Retained across starts, resumes, and forks.
946
+ * @default false
947
+ */
948
+ enable_service_ingress: boolean;
839
949
  /** @description Environment variables applied to every process */
840
950
  env?: {
841
951
  [key: string]: string;
@@ -2600,6 +2710,121 @@ export interface operations {
2600
2710
  500: components["responses"]["InternalError"];
2601
2711
  };
2602
2712
  };
2713
+ listSandboxPortTokens: {
2714
+ parameters: {
2715
+ query?: {
2716
+ /** @description Maximum number of items to return. Omit to return all items in a single unpaginated response; when set, the response may include a nextCursor to fetch the next page. */
2717
+ limit?: components["parameters"]["Limit"];
2718
+ /** @description Pagination cursor from a previous response */
2719
+ cursor?: components["parameters"]["Cursor"];
2720
+ };
2721
+ header?: never;
2722
+ path: {
2723
+ /** @description Sandbox UUID */
2724
+ sid: components["parameters"]["SandboxId"];
2725
+ };
2726
+ cookie?: never;
2727
+ };
2728
+ requestBody?: never;
2729
+ responses: {
2730
+ /** @description Sandbox port tokens */
2731
+ 200: {
2732
+ headers: {
2733
+ [name: string]: unknown;
2734
+ };
2735
+ content: {
2736
+ "application/json": components["schemas"]["ApiResponse_SandboxPortTokenList"];
2737
+ };
2738
+ };
2739
+ 400: components["responses"]["ValidationError"];
2740
+ 401: components["responses"]["Unauthorized"];
2741
+ 404: components["responses"]["NotFound"];
2742
+ 500: components["responses"]["InternalError"];
2743
+ };
2744
+ };
2745
+ createSandboxPortToken: {
2746
+ parameters: {
2747
+ query?: never;
2748
+ header?: never;
2749
+ path: {
2750
+ /** @description Sandbox UUID */
2751
+ sid: components["parameters"]["SandboxId"];
2752
+ };
2753
+ cookie?: never;
2754
+ };
2755
+ requestBody: {
2756
+ content: {
2757
+ "application/json": components["schemas"]["CreateSandboxPortTokenRequest"];
2758
+ };
2759
+ };
2760
+ responses: {
2761
+ /** @description Port token was created */
2762
+ 201: {
2763
+ headers: {
2764
+ [name: string]: unknown;
2765
+ };
2766
+ content: {
2767
+ "application/json": components["schemas"]["ApiResponse_CreatedSandboxPortToken"];
2768
+ };
2769
+ };
2770
+ 400: components["responses"]["ValidationError"];
2771
+ 401: components["responses"]["Unauthorized"];
2772
+ 404: components["responses"]["NotFound"];
2773
+ 500: components["responses"]["InternalError"];
2774
+ };
2775
+ };
2776
+ getSandboxPortToken: {
2777
+ parameters: {
2778
+ query?: never;
2779
+ header?: never;
2780
+ path: {
2781
+ /** @description Sandbox UUID */
2782
+ sid: components["parameters"]["SandboxId"];
2783
+ token_id: string;
2784
+ };
2785
+ cookie?: never;
2786
+ };
2787
+ requestBody?: never;
2788
+ responses: {
2789
+ /** @description Sandbox port token */
2790
+ 200: {
2791
+ headers: {
2792
+ [name: string]: unknown;
2793
+ };
2794
+ content: {
2795
+ "application/json": components["schemas"]["ApiResponse_SandboxPortToken"];
2796
+ };
2797
+ };
2798
+ 401: components["responses"]["Unauthorized"];
2799
+ 404: components["responses"]["NotFound"];
2800
+ 500: components["responses"]["InternalError"];
2801
+ };
2802
+ };
2803
+ deleteSandboxPortToken: {
2804
+ parameters: {
2805
+ query?: never;
2806
+ header?: never;
2807
+ path: {
2808
+ /** @description Sandbox UUID */
2809
+ sid: components["parameters"]["SandboxId"];
2810
+ token_id: string;
2811
+ };
2812
+ cookie?: never;
2813
+ };
2814
+ requestBody?: never;
2815
+ responses: {
2816
+ /** @description Port token was revoked */
2817
+ 204: {
2818
+ headers: {
2819
+ [name: string]: unknown;
2820
+ };
2821
+ content?: never;
2822
+ };
2823
+ 401: components["responses"]["Unauthorized"];
2824
+ 404: components["responses"]["NotFound"];
2825
+ 500: components["responses"]["InternalError"];
2826
+ };
2827
+ };
2603
2828
  pauseSandbox: {
2604
2829
  parameters: {
2605
2830
  query?: never;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@archildata/api-types",
3
- "version": "0.0.38",
3
+ "version": "0.0.40",
4
4
  "description": "API types for the Archil control plane",
5
5
  "type": "module",
6
6
  "types": "index.d.ts",