@sealant/api-contracts-next 0.40.0-next.764 → 0.40.0-next.765
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/core-api/control-plane.d.ts +1247 -1180
- package/dist/core-api/system.d.ts +4 -0
- package/dist/core-api/system.js +2 -0
- package/dist/core-api/workspaces.d.ts +204 -1
- package/dist/core-api/workspaces.js +46 -0
- package/package.json +2 -2
|
@@ -63,6 +63,8 @@ export declare const systemIndexResponseSchema: Schema.Struct<{
|
|
|
63
63
|
* `sudo` work, and the Kubernetes image builder records the image probe the launch checks.
|
|
64
64
|
*/
|
|
65
65
|
readonly kubernetesPersonLayout: Schema.optional<Schema.Boolean>;
|
|
66
|
+
/** Credential homes answer placement receipts; a put takes `live`; prune exists. */
|
|
67
|
+
readonly credentialPlacements: Schema.optional<Schema.Boolean>;
|
|
66
68
|
}>>;
|
|
67
69
|
}>;
|
|
68
70
|
export type SystemIndexResponse = typeof systemIndexResponseSchema.Type;
|
|
@@ -153,6 +155,8 @@ export declare const SystemGroup: HttpApiGroup.HttpApiGroup<"system", HttpApiEnd
|
|
|
153
155
|
* `sudo` work, and the Kubernetes image builder records the image probe the launch checks.
|
|
154
156
|
*/
|
|
155
157
|
readonly kubernetesPersonLayout: Schema.optional<Schema.Boolean>;
|
|
158
|
+
/** Credential homes answer placement receipts; a put takes `live`; prune exists. */
|
|
159
|
+
readonly credentialPlacements: Schema.optional<Schema.Boolean>;
|
|
156
160
|
}>>;
|
|
157
161
|
}>>, never, never, never> | HttpApiEndpoint.HttpApiEndpoint<"getSetupState", "GET", "/v1/system/setup-state", never, never, never, never, Schema.toCodecJson<Schema.Struct<{
|
|
158
162
|
readonly needsSetup: Schema.Boolean;
|
package/dist/core-api/system.js
CHANGED
|
@@ -64,6 +64,8 @@ export const systemIndexResponseSchema = Schema.Struct({
|
|
|
64
64
|
* `sudo` work, and the Kubernetes image builder records the image probe the launch checks.
|
|
65
65
|
*/
|
|
66
66
|
kubernetesPersonLayout: Schema.optional(Schema.Boolean),
|
|
67
|
+
/** Credential homes answer placement receipts; a put takes `live`; prune exists. */
|
|
68
|
+
credentialPlacements: Schema.optional(Schema.Boolean),
|
|
67
69
|
})),
|
|
68
70
|
});
|
|
69
71
|
export const systemHealthResponseSchema = Schema.Struct({
|
|
@@ -857,8 +857,36 @@ export declare const putWorkspaceCredentialsRequestSchema: Schema.Struct<{
|
|
|
857
857
|
* of the whole put failing. Every other refusal still fails the put. Default false.
|
|
858
858
|
*/
|
|
859
859
|
readonly partial: Schema.optional<Schema.Boolean>;
|
|
860
|
+
/**
|
|
861
|
+
* The placements the person's running processes hold in this home: a provider whose slot one of
|
|
862
|
+
* them holds is not written over with another login. Absent, nothing is held.
|
|
863
|
+
*/
|
|
864
|
+
readonly live: Schema.optional<Schema.$Array<Schema.String>>;
|
|
860
865
|
}>;
|
|
861
866
|
export type PutWorkspaceCredentialsRequest = typeof putWorkspaceCredentialsRequestSchema.Type;
|
|
867
|
+
/** One login written into one home: its id stays the same while a refresh moves its revision. */
|
|
868
|
+
export declare const credentialPlacementReceiptSchema: Schema.Struct<{
|
|
869
|
+
readonly placementId: Schema.String;
|
|
870
|
+
readonly accountId: Schema.String;
|
|
871
|
+
readonly revision: Schema.Int;
|
|
872
|
+
readonly login: Schema.Struct<{
|
|
873
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
874
|
+
}>;
|
|
875
|
+
readonly pinned: Schema.Boolean;
|
|
876
|
+
}>;
|
|
877
|
+
export type CredentialPlacementReceipt = typeof credentialPlacementReceiptSchema.Type;
|
|
878
|
+
/** A receipt tagged with the home provider whose slot it occupies. */
|
|
879
|
+
export declare const workspaceCredentialPlacementReceiptSchema: Schema.Struct<{
|
|
880
|
+
readonly placementId: Schema.String;
|
|
881
|
+
readonly accountId: Schema.String;
|
|
882
|
+
readonly revision: Schema.Int;
|
|
883
|
+
readonly login: Schema.Struct<{
|
|
884
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
885
|
+
}>;
|
|
886
|
+
readonly pinned: Schema.Boolean;
|
|
887
|
+
readonly provider: Schema.Literals<readonly ["claude", "codex", "github", "pi", "opencode"]>;
|
|
888
|
+
}>;
|
|
889
|
+
export type WorkspaceCredentialPlacementReceipt = typeof workspaceCredentialPlacementReceiptSchema.Type;
|
|
862
890
|
/** One account whose copy a home holds. */
|
|
863
891
|
export declare const workspaceHomeAccountSchema: Schema.Struct<{
|
|
864
892
|
readonly connectedAccountId: Schema.String;
|
|
@@ -871,6 +899,17 @@ export declare const workspaceCredentialHomeSchema: Schema.Struct<{
|
|
|
871
899
|
readonly home: Schema.String;
|
|
872
900
|
/** The one person whose logins the home holds. */
|
|
873
901
|
readonly onBehalfOfUserId: Schema.String;
|
|
902
|
+
/** The logins written there, one receipt each. Absent from a server without placements. */
|
|
903
|
+
readonly placements: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
904
|
+
readonly placementId: Schema.String;
|
|
905
|
+
readonly accountId: Schema.String;
|
|
906
|
+
readonly revision: Schema.Int;
|
|
907
|
+
readonly login: Schema.Struct<{
|
|
908
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
909
|
+
}>;
|
|
910
|
+
readonly pinned: Schema.Boolean;
|
|
911
|
+
readonly provider: Schema.Literals<readonly ["claude", "codex", "github", "pi", "opencode"]>;
|
|
912
|
+
}>>>;
|
|
874
913
|
/** By provider; a provider the home holds no login for is absent. */
|
|
875
914
|
readonly accounts: Schema.Struct<{
|
|
876
915
|
readonly claude: Schema.optional<Schema.Struct<{
|
|
@@ -924,6 +963,17 @@ export declare const putWorkspaceCredentialsResponseSchema: Schema.Struct<{
|
|
|
924
963
|
readonly home: Schema.String;
|
|
925
964
|
/** The one person whose logins the home holds. */
|
|
926
965
|
readonly onBehalfOfUserId: Schema.String;
|
|
966
|
+
/** The logins written there, one receipt each. Absent from a server without placements. */
|
|
967
|
+
readonly placements: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
968
|
+
readonly placementId: Schema.String;
|
|
969
|
+
readonly accountId: Schema.String;
|
|
970
|
+
readonly revision: Schema.Int;
|
|
971
|
+
readonly login: Schema.Struct<{
|
|
972
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
973
|
+
}>;
|
|
974
|
+
readonly pinned: Schema.Boolean;
|
|
975
|
+
readonly provider: Schema.Literals<readonly ["claude", "codex", "github", "pi", "opencode"]>;
|
|
976
|
+
}>>>;
|
|
927
977
|
/** By provider; a provider the home holds no login for is absent. */
|
|
928
978
|
readonly accounts: Schema.Struct<{
|
|
929
979
|
readonly claude: Schema.optional<Schema.Struct<{
|
|
@@ -968,6 +1018,65 @@ export declare const putWorkspaceCredentialsResponseSchema: Schema.Struct<{
|
|
|
968
1018
|
}>>>;
|
|
969
1019
|
}>;
|
|
970
1020
|
export type PutWorkspaceCredentialsResponse = typeof putWorkspaceCredentialsResponseSchema.Type;
|
|
1021
|
+
/** Remove every login of one home that is neither live nor the ready one of the person's default. */
|
|
1022
|
+
export declare const pruneWorkspaceCredentialsRequestSchema: Schema.Struct<{
|
|
1023
|
+
readonly ownerUserId: Schema.String;
|
|
1024
|
+
readonly home: Schema.String;
|
|
1025
|
+
readonly live: Schema.$Array<Schema.String>;
|
|
1026
|
+
}>;
|
|
1027
|
+
export type PruneWorkspaceCredentialsRequest = typeof pruneWorkspaceCredentialsRequestSchema.Type;
|
|
1028
|
+
export declare const pruneWorkspaceCredentialsResponseSchema: Schema.Struct<{
|
|
1029
|
+
readonly workspaceId: Schema.String;
|
|
1030
|
+
readonly runId: Schema.String;
|
|
1031
|
+
/** Absent when the home holds nothing (any more). */
|
|
1032
|
+
readonly home: Schema.optional<Schema.Struct<{
|
|
1033
|
+
readonly home: Schema.String;
|
|
1034
|
+
/** The one person whose logins the home holds. */
|
|
1035
|
+
readonly onBehalfOfUserId: Schema.String;
|
|
1036
|
+
/** The logins written there, one receipt each. Absent from a server without placements. */
|
|
1037
|
+
readonly placements: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
1038
|
+
readonly placementId: Schema.String;
|
|
1039
|
+
readonly accountId: Schema.String;
|
|
1040
|
+
readonly revision: Schema.Int;
|
|
1041
|
+
readonly login: Schema.Struct<{
|
|
1042
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
1043
|
+
}>;
|
|
1044
|
+
readonly pinned: Schema.Boolean;
|
|
1045
|
+
readonly provider: Schema.Literals<readonly ["claude", "codex", "github", "pi", "opencode"]>;
|
|
1046
|
+
}>>>;
|
|
1047
|
+
/** By provider; a provider the home holds no login for is absent. */
|
|
1048
|
+
readonly accounts: Schema.Struct<{
|
|
1049
|
+
readonly claude: Schema.optional<Schema.Struct<{
|
|
1050
|
+
readonly connectedAccountId: Schema.String;
|
|
1051
|
+
/** The account's name under its provider, as it is now. */
|
|
1052
|
+
readonly name: Schema.String;
|
|
1053
|
+
}>>;
|
|
1054
|
+
readonly codex: Schema.optional<Schema.Struct<{
|
|
1055
|
+
readonly connectedAccountId: Schema.String;
|
|
1056
|
+
/** The account's name under its provider, as it is now. */
|
|
1057
|
+
readonly name: Schema.String;
|
|
1058
|
+
}>>;
|
|
1059
|
+
readonly github: Schema.optional<Schema.Struct<{
|
|
1060
|
+
readonly connectedAccountId: Schema.String;
|
|
1061
|
+
/** The account's name under its provider, as it is now. */
|
|
1062
|
+
readonly name: Schema.String;
|
|
1063
|
+
}>>;
|
|
1064
|
+
/** The Codex account pi's ChatGPT login is made from. */
|
|
1065
|
+
readonly pi: Schema.optional<Schema.Struct<{
|
|
1066
|
+
readonly connectedAccountId: Schema.String;
|
|
1067
|
+
/** The account's name under its provider, as it is now. */
|
|
1068
|
+
readonly name: Schema.String;
|
|
1069
|
+
}>>;
|
|
1070
|
+
/** The Codex account opencode's ChatGPT login is made from. */
|
|
1071
|
+
readonly opencode: Schema.optional<Schema.Struct<{
|
|
1072
|
+
readonly connectedAccountId: Schema.String;
|
|
1073
|
+
/** The account's name under its provider, as it is now. */
|
|
1074
|
+
readonly name: Schema.String;
|
|
1075
|
+
}>>;
|
|
1076
|
+
}>;
|
|
1077
|
+
}>>;
|
|
1078
|
+
}>;
|
|
1079
|
+
export type PruneWorkspaceCredentialsResponse = typeof pruneWorkspaceCredentialsResponseSchema.Type;
|
|
971
1080
|
/** Release one home: its login files are removed and its record deleted. */
|
|
972
1081
|
export declare const releaseWorkspaceCredentialsQuerySchema: Schema.Struct<{
|
|
973
1082
|
readonly ownerUserId: Schema.String;
|
|
@@ -994,6 +1103,17 @@ export declare const listWorkspaceCredentialsResponseSchema: Schema.Struct<{
|
|
|
994
1103
|
readonly home: Schema.String;
|
|
995
1104
|
/** The one person whose logins the home holds. */
|
|
996
1105
|
readonly onBehalfOfUserId: Schema.String;
|
|
1106
|
+
/** The logins written there, one receipt each. Absent from a server without placements. */
|
|
1107
|
+
readonly placements: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
1108
|
+
readonly placementId: Schema.String;
|
|
1109
|
+
readonly accountId: Schema.String;
|
|
1110
|
+
readonly revision: Schema.Int;
|
|
1111
|
+
readonly login: Schema.Struct<{
|
|
1112
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
1113
|
+
}>;
|
|
1114
|
+
readonly pinned: Schema.Boolean;
|
|
1115
|
+
readonly provider: Schema.Literals<readonly ["claude", "codex", "github", "pi", "opencode"]>;
|
|
1116
|
+
}>>>;
|
|
997
1117
|
/** By provider; a provider the home holds no login for is absent. */
|
|
998
1118
|
readonly accounts: Schema.Struct<{
|
|
999
1119
|
readonly claude: Schema.optional<Schema.Struct<{
|
|
@@ -2712,6 +2832,17 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
2712
2832
|
readonly home: Schema.String;
|
|
2713
2833
|
/** The one person whose logins the home holds. */
|
|
2714
2834
|
readonly onBehalfOfUserId: Schema.String;
|
|
2835
|
+
/** The logins written there, one receipt each. Absent from a server without placements. */
|
|
2836
|
+
readonly placements: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2837
|
+
readonly placementId: Schema.String;
|
|
2838
|
+
readonly accountId: Schema.String;
|
|
2839
|
+
readonly revision: Schema.Int;
|
|
2840
|
+
readonly login: Schema.Struct<{
|
|
2841
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
2842
|
+
}>;
|
|
2843
|
+
readonly pinned: Schema.Boolean;
|
|
2844
|
+
readonly provider: Schema.Literals<readonly ["claude", "codex", "github", "pi", "opencode"]>;
|
|
2845
|
+
}>>>;
|
|
2715
2846
|
/** By provider; a provider the home holds no login for is absent. */
|
|
2716
2847
|
readonly accounts: Schema.Struct<{
|
|
2717
2848
|
readonly claude: Schema.optional<Schema.Struct<{
|
|
@@ -2849,7 +2980,63 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
2849
2980
|
readonly finishedAt: Schema.optional<Schema.String>;
|
|
2850
2981
|
readonly expiresAt: Schema.optional<Schema.String>;
|
|
2851
2982
|
}>>;
|
|
2852
|
-
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"
|
|
2983
|
+
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"pruneWorkspaceCredentials", "POST", "/:workspaceId/credentials/prune", Schema.toCodecStringTree<Schema.Struct<{
|
|
2984
|
+
readonly workspaceId: Schema.String;
|
|
2985
|
+
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
2986
|
+
readonly ownerUserId: Schema.String;
|
|
2987
|
+
readonly home: Schema.String;
|
|
2988
|
+
readonly live: Schema.$Array<Schema.String>;
|
|
2989
|
+
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
2990
|
+
readonly workspaceId: Schema.String;
|
|
2991
|
+
readonly runId: Schema.String;
|
|
2992
|
+
/** Absent when the home holds nothing (any more). */
|
|
2993
|
+
readonly home: Schema.optional<Schema.Struct<{
|
|
2994
|
+
readonly home: Schema.String;
|
|
2995
|
+
/** The one person whose logins the home holds. */
|
|
2996
|
+
readonly onBehalfOfUserId: Schema.String;
|
|
2997
|
+
/** The logins written there, one receipt each. Absent from a server without placements. */
|
|
2998
|
+
readonly placements: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
2999
|
+
readonly placementId: Schema.String;
|
|
3000
|
+
readonly accountId: Schema.String;
|
|
3001
|
+
readonly revision: Schema.Int;
|
|
3002
|
+
readonly login: Schema.Struct<{
|
|
3003
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
3004
|
+
}>;
|
|
3005
|
+
readonly pinned: Schema.Boolean;
|
|
3006
|
+
readonly provider: Schema.Literals<readonly ["claude", "codex", "github", "pi", "opencode"]>;
|
|
3007
|
+
}>>>;
|
|
3008
|
+
/** By provider; a provider the home holds no login for is absent. */
|
|
3009
|
+
readonly accounts: Schema.Struct<{
|
|
3010
|
+
readonly claude: Schema.optional<Schema.Struct<{
|
|
3011
|
+
readonly connectedAccountId: Schema.String;
|
|
3012
|
+
/** The account's name under its provider, as it is now. */
|
|
3013
|
+
readonly name: Schema.String;
|
|
3014
|
+
}>>;
|
|
3015
|
+
readonly codex: Schema.optional<Schema.Struct<{
|
|
3016
|
+
readonly connectedAccountId: Schema.String;
|
|
3017
|
+
/** The account's name under its provider, as it is now. */
|
|
3018
|
+
readonly name: Schema.String;
|
|
3019
|
+
}>>;
|
|
3020
|
+
readonly github: Schema.optional<Schema.Struct<{
|
|
3021
|
+
readonly connectedAccountId: Schema.String;
|
|
3022
|
+
/** The account's name under its provider, as it is now. */
|
|
3023
|
+
readonly name: Schema.String;
|
|
3024
|
+
}>>;
|
|
3025
|
+
/** The Codex account pi's ChatGPT login is made from. */
|
|
3026
|
+
readonly pi: Schema.optional<Schema.Struct<{
|
|
3027
|
+
readonly connectedAccountId: Schema.String;
|
|
3028
|
+
/** The account's name under its provider, as it is now. */
|
|
3029
|
+
readonly name: Schema.String;
|
|
3030
|
+
}>>;
|
|
3031
|
+
/** The Codex account opencode's ChatGPT login is made from. */
|
|
3032
|
+
readonly opencode: Schema.optional<Schema.Struct<{
|
|
3033
|
+
readonly connectedAccountId: Schema.String;
|
|
3034
|
+
/** The account's name under its provider, as it is now. */
|
|
3035
|
+
readonly name: Schema.String;
|
|
3036
|
+
}>>;
|
|
3037
|
+
}>;
|
|
3038
|
+
}>>;
|
|
3039
|
+
}>>, Schema.toCodecJson<typeof WorkspaceBadRequestError | typeof WorkspaceForbiddenError | typeof WorkspaceNotFoundError | typeof WorkspaceConflictError | typeof WorkspaceBadGatewayError | typeof WorkspaceServiceUnavailableError | typeof WorkspaceInternalServerError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"putWorkspaceCredentials", "POST", "/:workspaceId/credentials", Schema.toCodecStringTree<Schema.Struct<{
|
|
2853
3040
|
readonly workspaceId: Schema.String;
|
|
2854
3041
|
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
2855
3042
|
/** The workspace's owner (owner scope; uniform 404 otherwise). */
|
|
@@ -2891,6 +3078,11 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
2891
3078
|
* of the whole put failing. Every other refusal still fails the put. Default false.
|
|
2892
3079
|
*/
|
|
2893
3080
|
readonly partial: Schema.optional<Schema.Boolean>;
|
|
3081
|
+
/**
|
|
3082
|
+
* The placements the person's running processes hold in this home: a provider whose slot one of
|
|
3083
|
+
* them holds is not written over with another login. Absent, nothing is held.
|
|
3084
|
+
*/
|
|
3085
|
+
readonly live: Schema.optional<Schema.$Array<Schema.String>>;
|
|
2894
3086
|
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
2895
3087
|
readonly workspaceId: Schema.String;
|
|
2896
3088
|
/** The launch attempt whose executor was written. */
|
|
@@ -2900,6 +3092,17 @@ export declare const WorkspacesGroup: HttpApiGroup.HttpApiGroup<"workspaces", Ht
|
|
|
2900
3092
|
readonly home: Schema.String;
|
|
2901
3093
|
/** The one person whose logins the home holds. */
|
|
2902
3094
|
readonly onBehalfOfUserId: Schema.String;
|
|
3095
|
+
/** The logins written there, one receipt each. Absent from a server without placements. */
|
|
3096
|
+
readonly placements: Schema.optional<Schema.$Array<Schema.Struct<{
|
|
3097
|
+
readonly placementId: Schema.String;
|
|
3098
|
+
readonly accountId: Schema.String;
|
|
3099
|
+
readonly revision: Schema.Int;
|
|
3100
|
+
readonly login: Schema.Struct<{
|
|
3101
|
+
readonly kind: Schema.Literal<"subscription">;
|
|
3102
|
+
}>;
|
|
3103
|
+
readonly pinned: Schema.Boolean;
|
|
3104
|
+
readonly provider: Schema.Literals<readonly ["claude", "codex", "github", "pi", "opencode"]>;
|
|
3105
|
+
}>>>;
|
|
2903
3106
|
/** By provider; a provider the home holds no login for is absent. */
|
|
2904
3107
|
readonly accounts: Schema.Struct<{
|
|
2905
3108
|
readonly claude: Schema.optional<Schema.Struct<{
|
|
@@ -735,6 +735,24 @@ export const putWorkspaceCredentialsRequestSchema = Schema.Struct({
|
|
|
735
735
|
* of the whole put failing. Every other refusal still fails the put. Default false.
|
|
736
736
|
*/
|
|
737
737
|
partial: Schema.optional(Schema.Boolean),
|
|
738
|
+
/**
|
|
739
|
+
* The placements the person's running processes hold in this home: a provider whose slot one of
|
|
740
|
+
* them holds is not written over with another login. Absent, nothing is held.
|
|
741
|
+
*/
|
|
742
|
+
live: Schema.optional(Schema.Array(NonEmptyString)),
|
|
743
|
+
});
|
|
744
|
+
/** One login written into one home: its id stays the same while a refresh moves its revision. */
|
|
745
|
+
export const credentialPlacementReceiptSchema = Schema.Struct({
|
|
746
|
+
placementId: NonEmptyString,
|
|
747
|
+
accountId: NonEmptyString,
|
|
748
|
+
revision: Schema.Int.check(Schema.isGreaterThan(0)),
|
|
749
|
+
login: Schema.Struct({ kind: Schema.Literal("subscription") }),
|
|
750
|
+
pinned: Schema.Boolean,
|
|
751
|
+
});
|
|
752
|
+
/** A receipt tagged with the home provider whose slot it occupies. */
|
|
753
|
+
export const workspaceCredentialPlacementReceiptSchema = Schema.Struct({
|
|
754
|
+
provider: Schema.Literals(workspaceCredentialHomeProviders),
|
|
755
|
+
...credentialPlacementReceiptSchema.fields,
|
|
738
756
|
});
|
|
739
757
|
/** One account whose copy a home holds. */
|
|
740
758
|
export const workspaceHomeAccountSchema = Schema.Struct({
|
|
@@ -747,6 +765,8 @@ export const workspaceCredentialHomeSchema = Schema.Struct({
|
|
|
747
765
|
home: NonEmptyString,
|
|
748
766
|
/** The one person whose logins the home holds. */
|
|
749
767
|
onBehalfOfUserId: NonEmptyString,
|
|
768
|
+
/** The logins written there, one receipt each. Absent from a server without placements. */
|
|
769
|
+
placements: Schema.optional(Schema.Array(workspaceCredentialPlacementReceiptSchema)),
|
|
750
770
|
/** By provider; a provider the home holds no login for is absent. */
|
|
751
771
|
accounts: Schema.Struct({
|
|
752
772
|
claude: Schema.optional(workspaceHomeAccountSchema),
|
|
@@ -778,6 +798,18 @@ export const putWorkspaceCredentialsResponseSchema = Schema.Struct({
|
|
|
778
798
|
/** A partial put's left-out providers, in the order named (empty when all were written). */
|
|
779
799
|
skipped: Schema.optional(Schema.Array(workspaceCredentialSkipSchema)),
|
|
780
800
|
});
|
|
801
|
+
/** Remove every login of one home that is neither live nor the ready one of the person's default. */
|
|
802
|
+
export const pruneWorkspaceCredentialsRequestSchema = Schema.Struct({
|
|
803
|
+
ownerUserId: NonEmptyString,
|
|
804
|
+
home: NonEmptyString,
|
|
805
|
+
live: Schema.Array(NonEmptyString),
|
|
806
|
+
});
|
|
807
|
+
export const pruneWorkspaceCredentialsResponseSchema = Schema.Struct({
|
|
808
|
+
workspaceId: NonEmptyString,
|
|
809
|
+
runId: NonEmptyString,
|
|
810
|
+
/** Absent when the home holds nothing (any more). */
|
|
811
|
+
home: Schema.optional(workspaceCredentialHomeSchema),
|
|
812
|
+
});
|
|
781
813
|
/** Release one home: its login files are removed and its record deleted. */
|
|
782
814
|
export const releaseWorkspaceCredentialsQuerySchema = Schema.Struct({
|
|
783
815
|
ownerUserId: NonEmptyString,
|
|
@@ -1459,6 +1491,20 @@ HttpApiEndpoint.delete("releaseWorkspaceCredentials", "/:workspaceId/credentials
|
|
|
1459
1491
|
WorkspaceServiceUnavailableError,
|
|
1460
1492
|
WorkspaceInternalServerError,
|
|
1461
1493
|
],
|
|
1494
|
+
}))
|
|
1495
|
+
.add(HttpApiEndpoint.post("pruneWorkspaceCredentials", "/:workspaceId/credentials/prune", {
|
|
1496
|
+
params: workspaceIdParams,
|
|
1497
|
+
payload: pruneWorkspaceCredentialsRequestSchema,
|
|
1498
|
+
success: pruneWorkspaceCredentialsResponseSchema,
|
|
1499
|
+
error: [
|
|
1500
|
+
WorkspaceBadRequestError,
|
|
1501
|
+
WorkspaceForbiddenError,
|
|
1502
|
+
WorkspaceNotFoundError,
|
|
1503
|
+
WorkspaceConflictError,
|
|
1504
|
+
WorkspaceBadGatewayError,
|
|
1505
|
+
WorkspaceServiceUnavailableError,
|
|
1506
|
+
WorkspaceInternalServerError,
|
|
1507
|
+
],
|
|
1462
1508
|
}))
|
|
1463
1509
|
.add(HttpApiEndpoint.get("listWorkspaceCredentials", "/:workspaceId/credentials", {
|
|
1464
1510
|
params: workspaceIdParams,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sealant/api-contracts-next",
|
|
3
|
-
"version": "0.40.0-next.
|
|
3
|
+
"version": "0.40.0-next.765",
|
|
4
4
|
"description": "Contract-first HTTP API definitions for Sealant services",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"peerDependencies": {
|
|
37
37
|
"effect": "^4.0.5"
|
|
38
38
|
},
|
|
39
|
-
"gitHead": "
|
|
39
|
+
"gitHead": "9802ef32e54645b875272fecf15d036bf7f095e1",
|
|
40
40
|
"publishConfig": {
|
|
41
41
|
"access": "public"
|
|
42
42
|
}
|