@xemahq/authorization-internal-api-client 0.5.3 → 0.8.0
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/endpoints/authorization/authorization.d.ts +1 -19
- package/dist/endpoints/authorization/authorization.js +1 -52
- package/dist/endpoints/authorization-policy-sets/authorization-policy-sets.d.ts +27 -0
- package/dist/endpoints/authorization-policy-sets/authorization-policy-sets.js +65 -0
- package/dist/endpoints/environments/environments.d.ts +6 -6
- package/dist/endpoints/environments/environments.js +16 -16
- package/dist/endpoints/output-routes/output-routes.d.ts +5 -5
- package/dist/endpoints/output-routes/output-routes.js +17 -17
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/models/adoptOrgPolicySetDto.d.ts +21 -0
- package/dist/models/dataClassification.d.ts +3 -0
- package/dist/models/executionEnvironmentKind.d.ts +1 -1
- package/dist/models/index.d.ts +15 -56
- package/dist/models/index.js +15 -56
- package/dist/models/orgPolicySetDto.d.ts +18 -0
- package/dist/models/orgPolicySetDtoDataEnvelope.d.ts +9 -0
- package/dist/models/{policyRouteHintDtoRequiredRunnerLabels.d.ts → orgPolicySetDtoModel.d.ts} +5 -2
- package/dist/models/orgPolicySetDtoModules.d.ts +11 -0
- package/dist/models/policySetTestFileDto.d.ts +22 -0
- package/dist/models/policySetTestFileResultDto.d.ts +11 -0
- package/dist/models/policySetTestResultsDto.d.ts +9 -0
- package/dist/models/policySetTestResultsDtoDataEnvelope.d.ts +9 -0
- package/dist/models/retiredNamespaceDto.d.ts +9 -0
- package/dist/models/retiredNamespaceDtoDataEnvelope.d.ts +9 -0
- package/dist/models/runPolicySetTestsDto.d.ts +12 -0
- package/dist/models/runPolicySetTestsDtoModel.d.ts +11 -0
- package/dist/models/runtimeModuleContributionDto.d.ts +20 -0
- package/dist/models/runtimeModuleContributionDtoManifest.d.ts +11 -0
- package/dist/models/runtimeModuleContributionDtoManifest.js +7 -0
- package/dist/models/spaceKind.d.ts +3 -0
- package/package.json +1 -1
- package/dist/endpoints/resources/resources.d.ts +0 -59
- package/dist/endpoints/resources/resources.js +0 -141
- package/dist/models/addResourceShareDto.d.ts +0 -12
- package/dist/models/authorizationCheckRequestDto.d.ts +0 -39
- package/dist/models/authorizationCheckResponseDto.d.ts +0 -14
- package/dist/models/authorizationCheckResponseDtoDataEnvelope.d.ts +0 -9
- package/dist/models/authorizationDecisionCode.d.ts +0 -18
- package/dist/models/authorizationDecisionCode.js +0 -20
- package/dist/models/authorizationReasonDto.d.ts +0 -11
- package/dist/models/authorizationSuggestionDto.d.ts +0 -25
- package/dist/models/authorizationSuggestionKind.d.ts +0 -11
- package/dist/models/authorizationSuggestionKind.js +0 -13
- package/dist/models/biomeExecutionTrustTier.d.ts +0 -10
- package/dist/models/biomeExecutionTrustTier.js +0 -12
- package/dist/models/callerKind.d.ts +0 -14
- package/dist/models/callerKind.js +0 -16
- package/dist/models/credentialPrecedenceSource.d.ts +0 -17
- package/dist/models/credentialPrecedenceSource.js +0 -16
- package/dist/models/dataResidency.d.ts +0 -9
- package/dist/models/dataResidency.js +0 -11
- package/dist/models/listRegisteredResourcesDto.d.ts +0 -12
- package/dist/models/listVisibleResourcesDto.d.ts +0 -20
- package/dist/models/policyActingAgentDto.d.ts +0 -14
- package/dist/models/policyActingAgentDtoKind.d.ts +0 -9
- package/dist/models/policyActingAgentDtoKind.js +0 -11
- package/dist/models/policyActingForDto.d.ts +0 -29
- package/dist/models/policyActingForDto.js +0 -2
- package/dist/models/policyBiomeDto.d.ts +0 -14
- package/dist/models/policyBiomeDto.js +0 -2
- package/dist/models/policyCallerDto.d.ts +0 -17
- package/dist/models/policyCallerDto.js +0 -2
- package/dist/models/policyCapabilityDto.d.ts +0 -14
- package/dist/models/policyCheckBatchRequestDto.d.ts +0 -13
- package/dist/models/policyCheckBatchRequestDto.js +0 -2
- package/dist/models/policyCheckBatchResponseDto.d.ts +0 -10
- package/dist/models/policyCheckBatchResponseDto.js +0 -2
- package/dist/models/policyCheckBatchResponseDtoDataEnvelope.d.ts +0 -9
- package/dist/models/policyCheckBatchResponseDtoDataEnvelope.js +0 -2
- package/dist/models/policyCheckRequestDto.d.ts +0 -96
- package/dist/models/policyCheckRequestDto.js +0 -2
- package/dist/models/policyCheckRequestDtoAperture.d.ts +0 -11
- package/dist/models/policyConstraintsDto.d.ts +0 -12
- package/dist/models/policyDecisionDto.d.ts +0 -26
- package/dist/models/policyDecisionDto.js +0 -2
- package/dist/models/policyDecisionDtoDataEnvelope.d.ts +0 -9
- package/dist/models/policyDecisionDtoDataEnvelope.js +0 -2
- package/dist/models/policyDecisionKind.d.ts +0 -11
- package/dist/models/policyDecisionKind.js +0 -13
- package/dist/models/policyDelegatedAuthorityDto.d.ts +0 -25
- package/dist/models/policyDelegatedAuthorityDto.js +0 -2
- package/dist/models/policyEnvironmentDto.d.ts +0 -15
- package/dist/models/policyEnvironmentDto.js +0 -2
- package/dist/models/policyObligationDto.d.ts +0 -29
- package/dist/models/policyObligationDto.js +0 -2
- package/dist/models/policyObligationKind.d.ts +0 -17
- package/dist/models/policyObligationKind.js +0 -19
- package/dist/models/policyResourceDto.d.ts +0 -15
- package/dist/models/policyResourceDto.js +0 -2
- package/dist/models/policyRouteHintDto.d.ts +0 -14
- package/dist/models/policyRouteHintDto.js +0 -2
- package/dist/models/policySpaceRefDto.d.ts +0 -23
- package/dist/models/policySpaceRefDto.js +0 -2
- package/dist/models/policySubjectRefDto.d.ts +0 -14
- package/dist/models/policySubjectRefDto.js +0 -2
- package/dist/models/registerResourceOwnershipDto.d.ts +0 -34
- package/dist/models/registerResourceOwnershipDto.js +0 -2
- package/dist/models/registeredResourceDto.d.ts +0 -12
- package/dist/models/registeredResourceDto.js +0 -2
- package/dist/models/registeredResourcesDto.d.ts +0 -10
- package/dist/models/registeredResourcesDto.js +0 -2
- package/dist/models/registeredResourcesDtoDataEnvelope.d.ts +0 -9
- package/dist/models/registeredResourcesDtoDataEnvelope.js +0 -2
- package/dist/models/removeResourceShareDto.d.ts +0 -10
- package/dist/models/removeResourceShareDto.js +0 -2
- package/dist/models/replaceResourceOwnershipDto.d.ts +0 -34
- package/dist/models/replaceResourceOwnershipDto.js +0 -2
- package/dist/models/resourceOwnershipDto.d.ts +0 -15
- package/dist/models/resourceOwnershipDto.js +0 -2
- package/dist/models/resourceOwnershipDtoDataEnvelope.d.ts +0 -9
- package/dist/models/resourceOwnershipDtoDataEnvelope.js +0 -2
- package/dist/models/resourceOwnershipEntryDto.d.ts +0 -17
- package/dist/models/resourceOwnershipEntryDto.js +0 -2
- package/dist/models/resourceOwnershipReadDto.d.ts +0 -16
- package/dist/models/resourceOwnershipReadDto.js +0 -2
- package/dist/models/resourceOwnershipReadDtoDataEnvelope.d.ts +0 -9
- package/dist/models/resourceOwnershipReadDtoDataEnvelope.js +0 -2
- package/dist/models/resourceShareRefDto.d.ts +0 -21
- package/dist/models/resourceShareRefDto.js +0 -2
- package/dist/models/resourceVisibilityPattern.d.ts +0 -11
- package/dist/models/resourceVisibilityPattern.js +0 -13
- package/dist/models/runnerKind.d.ts +0 -15
- package/dist/models/runnerKind.js +0 -17
- package/dist/models/sessionParticipantRole.d.ts +0 -14
- package/dist/models/sessionParticipantRole.js +0 -13
- package/dist/models/subjectRefDto.d.ts +0 -15
- package/dist/models/subjectRefDto.js +0 -2
- package/dist/models/visibleResourcesDto.d.ts +0 -9
- package/dist/models/visibleResourcesDtoDataEnvelope.d.ts +0 -9
- package/dist/models/visibleResourcesDtoDataEnvelope.js +0 -2
- /package/dist/models/{addResourceShareDto.js → adoptOrgPolicySetDto.js} +0 -0
- /package/dist/models/{authorizationCheckRequestDto.js → orgPolicySetDto.js} +0 -0
- /package/dist/models/{authorizationCheckResponseDto.js → orgPolicySetDtoDataEnvelope.js} +0 -0
- /package/dist/models/{listRegisteredResourcesDto.js → orgPolicySetDtoModel.js} +0 -0
- /package/dist/models/{policyCapabilityDto.js → orgPolicySetDtoModules.js} +0 -0
- /package/dist/models/{policyCheckRequestDtoAperture.js → policySetTestFileDto.js} +0 -0
- /package/dist/models/{policyConstraintsDto.js → policySetTestFileResultDto.js} +0 -0
- /package/dist/models/{authorizationCheckResponseDtoDataEnvelope.js → policySetTestResultsDto.js} +0 -0
- /package/dist/models/{authorizationReasonDto.js → policySetTestResultsDtoDataEnvelope.js} +0 -0
- /package/dist/models/{policyRouteHintDtoRequiredRunnerLabels.js → retiredNamespaceDto.js} +0 -0
- /package/dist/models/{authorizationSuggestionDto.js → retiredNamespaceDtoDataEnvelope.js} +0 -0
- /package/dist/models/{listVisibleResourcesDto.js → runPolicySetTestsDto.js} +0 -0
- /package/dist/models/{visibleResourcesDto.js → runPolicySetTestsDtoModel.js} +0 -0
- /package/dist/models/{policyActingAgentDto.js → runtimeModuleContributionDto.js} +0 -0
package/dist/models/index.js
CHANGED
|
@@ -15,24 +15,15 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
// Auto-generated by tooling/codegen/regenerate-models-barrel.js — do not edit manually.
|
|
18
|
-
__exportStar(require("./addResourceShareDto"), exports);
|
|
19
18
|
__exportStar(require("./addRoleGrantDto"), exports);
|
|
20
19
|
__exportStar(require("./addTeamMemberDto"), exports);
|
|
20
|
+
__exportStar(require("./adoptOrgPolicySetDto"), exports);
|
|
21
21
|
__exportStar(require("./agentProvisionDecision"), exports);
|
|
22
22
|
__exportStar(require("./agentProvisionReason"), exports);
|
|
23
23
|
__exportStar(require("./agentReachTier"), exports);
|
|
24
24
|
__exportStar(require("./assignRoleDto"), exports);
|
|
25
25
|
__exportStar(require("./authorityRowOwnerSpaceKind"), exports);
|
|
26
|
-
__exportStar(require("./authorizationCheckRequestDto"), exports);
|
|
27
|
-
__exportStar(require("./authorizationCheckResponseDto"), exports);
|
|
28
|
-
__exportStar(require("./authorizationCheckResponseDtoDataEnvelope"), exports);
|
|
29
|
-
__exportStar(require("./authorizationDecisionCode"), exports);
|
|
30
|
-
__exportStar(require("./authorizationReasonDto"), exports);
|
|
31
|
-
__exportStar(require("./authorizationSuggestionDto"), exports);
|
|
32
|
-
__exportStar(require("./authorizationSuggestionKind"), exports);
|
|
33
|
-
__exportStar(require("./biomeExecutionTrustTier"), exports);
|
|
34
26
|
__exportStar(require("./biomePermissionProfile"), exports);
|
|
35
|
-
__exportStar(require("./callerKind"), exports);
|
|
36
27
|
__exportStar(require("./capabilityAuthorityRequestDto"), exports);
|
|
37
28
|
__exportStar(require("./capabilityAuthorityRequestDtoDataArrayEnvelope"), exports);
|
|
38
29
|
__exportStar(require("./capabilityAuthorityRequestDtoDataEnvelope"), exports);
|
|
@@ -61,9 +52,7 @@ __exportStar(require("./credentialDefaultDtoDataEnvelope"), exports);
|
|
|
61
52
|
__exportStar(require("./credentialDefaultsControllerDeleteParams"), exports);
|
|
62
53
|
__exportStar(require("./credentialDefaultsControllerGetParams"), exports);
|
|
63
54
|
__exportStar(require("./credentialDefaultsControllerListParams"), exports);
|
|
64
|
-
__exportStar(require("./credentialPrecedenceSource"), exports);
|
|
65
55
|
__exportStar(require("./dataClassification"), exports);
|
|
66
|
-
__exportStar(require("./dataResidency"), exports);
|
|
67
56
|
__exportStar(require("./describeObjectsResponseDto"), exports);
|
|
68
57
|
__exportStar(require("./describeObjectsResponseDtoDataEnvelope"), exports);
|
|
69
58
|
__exportStar(require("./environmentCeilingSource"), exports);
|
|
@@ -100,14 +89,16 @@ __exportStar(require("./grantVersionResponseDtoDataEnvelope"), exports);
|
|
|
100
89
|
__exportStar(require("./grantsControllerListParams"), exports);
|
|
101
90
|
__exportStar(require("./impactedOutputRouteConsumerDto"), exports);
|
|
102
91
|
__exportStar(require("./impactedOutputRouteConsumerDtoDataArrayEnvelope"), exports);
|
|
103
|
-
__exportStar(require("./listRegisteredResourcesDto"), exports);
|
|
104
|
-
__exportStar(require("./listVisibleResourcesDto"), exports);
|
|
105
92
|
__exportStar(require("./object"), exports);
|
|
106
93
|
__exportStar(require("./objectLifecycle"), exports);
|
|
107
94
|
__exportStar(require("./openCapabilityAuthorityRequestDto"), exports);
|
|
108
95
|
__exportStar(require("./openCapabilityAuthorityRequestDtoSubjectKind"), exports);
|
|
109
96
|
__exportStar(require("./openFgaRelationshipDto"), exports);
|
|
110
97
|
__exportStar(require("./openFgaRelationshipDtoPaginatedEnvelope"), exports);
|
|
98
|
+
__exportStar(require("./orgPolicySetDto"), exports);
|
|
99
|
+
__exportStar(require("./orgPolicySetDtoDataEnvelope"), exports);
|
|
100
|
+
__exportStar(require("./orgPolicySetDtoModel"), exports);
|
|
101
|
+
__exportStar(require("./orgPolicySetDtoModules"), exports);
|
|
111
102
|
__exportStar(require("./outputRouteAuthorityDto"), exports);
|
|
112
103
|
__exportStar(require("./outputRouteAuthorityDtoAllowedOutputSchema"), exports);
|
|
113
104
|
__exportStar(require("./outputRouteAuthorityDtoDataEnvelope"), exports);
|
|
@@ -124,30 +115,10 @@ __exportStar(require("./outputRouteRevisionDto"), exports);
|
|
|
124
115
|
__exportStar(require("./outputRouteRevisionDtoAllowedOutputSchema"), exports);
|
|
125
116
|
__exportStar(require("./outputRouteRevisionsControllerReleaseHistoryParams"), exports);
|
|
126
117
|
__exportStar(require("./paginationMeta"), exports);
|
|
127
|
-
__exportStar(require("./
|
|
128
|
-
__exportStar(require("./
|
|
129
|
-
__exportStar(require("./
|
|
130
|
-
__exportStar(require("./
|
|
131
|
-
__exportStar(require("./policyCallerDto"), exports);
|
|
132
|
-
__exportStar(require("./policyCapabilityDto"), exports);
|
|
133
|
-
__exportStar(require("./policyCheckBatchRequestDto"), exports);
|
|
134
|
-
__exportStar(require("./policyCheckBatchResponseDto"), exports);
|
|
135
|
-
__exportStar(require("./policyCheckBatchResponseDtoDataEnvelope"), exports);
|
|
136
|
-
__exportStar(require("./policyCheckRequestDto"), exports);
|
|
137
|
-
__exportStar(require("./policyCheckRequestDtoAperture"), exports);
|
|
138
|
-
__exportStar(require("./policyConstraintsDto"), exports);
|
|
139
|
-
__exportStar(require("./policyDecisionDto"), exports);
|
|
140
|
-
__exportStar(require("./policyDecisionDtoDataEnvelope"), exports);
|
|
141
|
-
__exportStar(require("./policyDecisionKind"), exports);
|
|
142
|
-
__exportStar(require("./policyDelegatedAuthorityDto"), exports);
|
|
143
|
-
__exportStar(require("./policyEnvironmentDto"), exports);
|
|
144
|
-
__exportStar(require("./policyObligationDto"), exports);
|
|
145
|
-
__exportStar(require("./policyObligationKind"), exports);
|
|
146
|
-
__exportStar(require("./policyResourceDto"), exports);
|
|
147
|
-
__exportStar(require("./policyRouteHintDto"), exports);
|
|
148
|
-
__exportStar(require("./policyRouteHintDtoRequiredRunnerLabels"), exports);
|
|
149
|
-
__exportStar(require("./policySpaceRefDto"), exports);
|
|
150
|
-
__exportStar(require("./policySubjectRefDto"), exports);
|
|
118
|
+
__exportStar(require("./policySetTestFileDto"), exports);
|
|
119
|
+
__exportStar(require("./policySetTestFileResultDto"), exports);
|
|
120
|
+
__exportStar(require("./policySetTestResultsDto"), exports);
|
|
121
|
+
__exportStar(require("./policySetTestResultsDtoDataEnvelope"), exports);
|
|
151
122
|
__exportStar(require("./previewOutputRouteImpactDto"), exports);
|
|
152
123
|
__exportStar(require("./problemActionableBy"), exports);
|
|
153
124
|
__exportStar(require("./problemDetailsDto"), exports);
|
|
@@ -163,16 +134,10 @@ __exportStar(require("./provisionAgentResultDto"), exports);
|
|
|
163
134
|
__exportStar(require("./provisionAgentResultDtoDataEnvelope"), exports);
|
|
164
135
|
__exportStar(require("./provisionedCapabilityDto"), exports);
|
|
165
136
|
__exportStar(require("./recordAgentReachTierRequestDto"), exports);
|
|
166
|
-
__exportStar(require("./registerResourceOwnershipDto"), exports);
|
|
167
137
|
__exportStar(require("./registerResourceRevisionDto"), exports);
|
|
168
|
-
__exportStar(require("./registeredResourceDto"), exports);
|
|
169
138
|
__exportStar(require("./registeredResourceRevisionDto"), exports);
|
|
170
139
|
__exportStar(require("./registeredResourceRevisionDtoDataEnvelope"), exports);
|
|
171
|
-
__exportStar(require("./registeredResourcesDto"), exports);
|
|
172
|
-
__exportStar(require("./registeredResourcesDtoDataEnvelope"), exports);
|
|
173
140
|
__exportStar(require("./relationshipsControllerListParams"), exports);
|
|
174
|
-
__exportStar(require("./removeResourceShareDto"), exports);
|
|
175
|
-
__exportStar(require("./replaceResourceOwnershipDto"), exports);
|
|
176
141
|
__exportStar(require("./requestOutputRouteRetirementDto"), exports);
|
|
177
142
|
__exportStar(require("./requestOutputRouteRevisionReleaseDto"), exports);
|
|
178
143
|
__exportStar(require("./requestOutputRouteRevisionReleaseDtoAllowedOutputSchema"), exports);
|
|
@@ -181,15 +146,10 @@ __exportStar(require("./resolveExactOutputRouteDto"), exports);
|
|
|
181
146
|
__exportStar(require("./resolveExactResourceRevisionDto"), exports);
|
|
182
147
|
__exportStar(require("./resolveOutputRouteChannelDto"), exports);
|
|
183
148
|
__exportStar(require("./resourceManagedBy"), exports);
|
|
184
|
-
__exportStar(require("./resourceOwnershipDto"), exports);
|
|
185
|
-
__exportStar(require("./resourceOwnershipDtoDataEnvelope"), exports);
|
|
186
|
-
__exportStar(require("./resourceOwnershipEntryDto"), exports);
|
|
187
|
-
__exportStar(require("./resourceOwnershipReadDto"), exports);
|
|
188
|
-
__exportStar(require("./resourceOwnershipReadDtoDataEnvelope"), exports);
|
|
189
|
-
__exportStar(require("./resourceShareRefDto"), exports);
|
|
190
149
|
__exportStar(require("./resourceSubjectAccessResult"), exports);
|
|
191
150
|
__exportStar(require("./resourceSubjectRefDto"), exports);
|
|
192
|
-
__exportStar(require("./
|
|
151
|
+
__exportStar(require("./retiredNamespaceDto"), exports);
|
|
152
|
+
__exportStar(require("./retiredNamespaceDtoDataEnvelope"), exports);
|
|
193
153
|
__exportStar(require("./roleAssignmentDto"), exports);
|
|
194
154
|
__exportStar(require("./roleAssignmentDtoDataArrayEnvelope"), exports);
|
|
195
155
|
__exportStar(require("./roleAssignmentDtoDataEnvelope"), exports);
|
|
@@ -201,11 +161,12 @@ __exportStar(require("./roleGrantDtoDataArrayEnvelope"), exports);
|
|
|
201
161
|
__exportStar(require("./roleGrantDtoDataEnvelope"), exports);
|
|
202
162
|
__exportStar(require("./rolesControllerListParams"), exports);
|
|
203
163
|
__exportStar(require("./rollbackExecutionEnvironmentDto"), exports);
|
|
204
|
-
__exportStar(require("./
|
|
205
|
-
__exportStar(require("./
|
|
164
|
+
__exportStar(require("./runPolicySetTestsDto"), exports);
|
|
165
|
+
__exportStar(require("./runPolicySetTestsDtoModel"), exports);
|
|
166
|
+
__exportStar(require("./runtimeModuleContributionDto"), exports);
|
|
167
|
+
__exportStar(require("./runtimeModuleContributionDtoManifest"), exports);
|
|
206
168
|
__exportStar(require("./spaceKind"), exports);
|
|
207
169
|
__exportStar(require("./subjectKind"), exports);
|
|
208
|
-
__exportStar(require("./subjectRefDto"), exports);
|
|
209
170
|
__exportStar(require("./teamDto"), exports);
|
|
210
171
|
__exportStar(require("./teamDtoDataArrayEnvelope"), exports);
|
|
211
172
|
__exportStar(require("./teamDtoDataEnvelope"), exports);
|
|
@@ -221,8 +182,6 @@ __exportStar(require("./updateGrantDto"), exports);
|
|
|
221
182
|
__exportStar(require("./updateRoleDto"), exports);
|
|
222
183
|
__exportStar(require("./updateTeamDto"), exports);
|
|
223
184
|
__exportStar(require("./upsertCredentialDefaultDto"), exports);
|
|
224
|
-
__exportStar(require("./visibleResourcesDto"), exports);
|
|
225
|
-
__exportStar(require("./visibleResourcesDtoDataEnvelope"), exports);
|
|
226
185
|
__exportStar(require("./xemaObjectKind"), exports);
|
|
227
186
|
__exportStar(require("./xemaObjectResponseDto"), exports);
|
|
228
187
|
__exportStar(require("./xemaObjectResponseDtoPayload"), exports);
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
import type { OrgPolicySetDtoModel } from './orgPolicySetDtoModel.js';
|
|
7
|
+
import type { OrgPolicySetDtoModules } from './orgPolicySetDtoModules.js';
|
|
8
|
+
export interface OrgPolicySetDto {
|
|
9
|
+
/**
|
|
10
|
+
* The policy set content address, or null for the base.
|
|
11
|
+
* @nullable
|
|
12
|
+
*/
|
|
13
|
+
policySetId: string | null;
|
|
14
|
+
/** The OpenFGA JSON model. */
|
|
15
|
+
model?: OrgPolicySetDtoModel;
|
|
16
|
+
/** namespace → { moduleVersion, contentHash }. */
|
|
17
|
+
modules?: OrgPolicySetDtoModules;
|
|
18
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
import type { OrgPolicySetDto } from './orgPolicySetDto.js';
|
|
7
|
+
export interface OrgPolicySetDtoDataEnvelope {
|
|
8
|
+
data: OrgPolicySetDto;
|
|
9
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* namespace → { moduleVersion, contentHash }.
|
|
8
|
+
*/
|
|
9
|
+
export type OrgPolicySetDtoModules = {
|
|
10
|
+
[key: string]: unknown;
|
|
11
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
export interface PolicySetTestFileDto {
|
|
7
|
+
/**
|
|
8
|
+
* The module the file belongs to (`xema_core`, a biome id).
|
|
9
|
+
* @minLength 1
|
|
10
|
+
*/
|
|
11
|
+
owner: string;
|
|
12
|
+
/**
|
|
13
|
+
* The file name, e.g. `pai-core.fga.yaml`.
|
|
14
|
+
* @minLength 1
|
|
15
|
+
*/
|
|
16
|
+
name: string;
|
|
17
|
+
/**
|
|
18
|
+
* The standard OpenFGA test file (`fga model test`) as YAML.
|
|
19
|
+
* @minLength 1
|
|
20
|
+
*/
|
|
21
|
+
contents: string;
|
|
22
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
import type { PolicySetTestFileResultDto } from './policySetTestFileResultDto.js';
|
|
7
|
+
export interface PolicySetTestResultsDto {
|
|
8
|
+
results: PolicySetTestFileResultDto[];
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
import type { PolicySetTestResultsDto } from './policySetTestResultsDto.js';
|
|
7
|
+
export interface PolicySetTestResultsDtoDataEnvelope {
|
|
8
|
+
data: PolicySetTestResultsDto;
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
import type { RetiredNamespaceDto } from './retiredNamespaceDto.js';
|
|
7
|
+
export interface RetiredNamespaceDtoDataEnvelope {
|
|
8
|
+
data: RetiredNamespaceDto;
|
|
9
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
import type { PolicySetTestFileDto } from './policySetTestFileDto.js';
|
|
7
|
+
import type { RunPolicySetTestsDtoModel } from './runPolicySetTestsDtoModel.js';
|
|
8
|
+
export interface RunPolicySetTestsDto {
|
|
9
|
+
/** The composed OpenFGA JSON model. */
|
|
10
|
+
model: RunPolicySetTestsDtoModel;
|
|
11
|
+
testFiles: PolicySetTestFileDto[];
|
|
12
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
import type { RuntimeModuleContributionDtoManifest } from './runtimeModuleContributionDtoManifest.js';
|
|
7
|
+
export interface RuntimeModuleContributionDto {
|
|
8
|
+
/**
|
|
9
|
+
* The signed biome id (the derived namespace).
|
|
10
|
+
* @minLength 1
|
|
11
|
+
*/
|
|
12
|
+
biomeId: string;
|
|
13
|
+
/**
|
|
14
|
+
* The signed biome version the module was read from.
|
|
15
|
+
* @minLength 1
|
|
16
|
+
*/
|
|
17
|
+
biomeVersion: string;
|
|
18
|
+
/** The stamped authorization-module contribution manifest (envelope, files, tests, signedBiome). */
|
|
19
|
+
manifest: RuntimeModuleContributionDtoManifest;
|
|
20
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
+
* Authorization API
|
|
4
|
+
* OpenAPI spec version: 0.1.1
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* The stamped authorization-module contribution manifest (envelope, files, tests, signedBiome).
|
|
8
|
+
*/
|
|
9
|
+
export type RuntimeModuleContributionDtoManifest = {
|
|
10
|
+
[key: string]: unknown;
|
|
11
|
+
};
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Authorization API
|
|
4
4
|
* OpenAPI spec version: 0.1.1
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* The ref's tier — what an admin sees this as (a project, an app, the org).
|
|
8
|
+
*/
|
|
6
9
|
export type SpaceKind = typeof SpaceKind[keyof typeof SpaceKind];
|
|
7
10
|
export declare const SpaceKind: {
|
|
8
11
|
readonly system: "system";
|
package/package.json
CHANGED
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
-
* Authorization API
|
|
4
|
-
* OpenAPI spec version: 0.1.1
|
|
5
|
-
*/
|
|
6
|
-
import type { AddResourceShareDto, ListRegisteredResourcesDto, ListVisibleResourcesDto, RegisterResourceOwnershipDto, RegisteredResourcesDtoDataEnvelope, RemoveResourceShareDto, ReplaceResourceOwnershipDto, ResourceOwnershipDtoDataEnvelope, ResourceOwnershipReadDtoDataEnvelope, VisibleResourcesDtoDataEnvelope } from '../../models';
|
|
7
|
-
export declare const getResourcesControllerRegisterUrl: () => string;
|
|
8
|
-
/**
|
|
9
|
-
* Writes the ownership rows + OpenFGA tuples so the PDP ANDs the verb verdict with instance ownership. Idempotent (upsert + ignore-duplicate tuples). Org scope is forced from the caller context.
|
|
10
|
-
* @summary Register ownership/visibility of a resource instance
|
|
11
|
-
*/
|
|
12
|
-
export declare const resourcesControllerRegister: (registerResourceOwnershipDto: RegisterResourceOwnershipDto, options?: RequestInit) => Promise<ResourceOwnershipDtoDataEnvelope>;
|
|
13
|
-
export declare const getResourcesControllerListVisibleUrl: () => string;
|
|
14
|
-
/**
|
|
15
|
-
* Unions OpenFGA owner/shared-with visibility (usersets expanded transitively) with org-shared instances. Org scope is forced from the caller context. Used by platform BFFs to visibility-filter a list on behalf of the end user they serve.
|
|
16
|
-
*
|
|
17
|
-
* Supplying `minLevel` narrows the question from "may this subject SEE it" to "does this subject hold at least this LEVEL on it": the answer becomes owner ∪ shared at or above that rung, and org-shared instances drop out because org-shared is a visibility pattern rather than a rung. That is the question a BFF asks to decide who may MANAGE an instance, and answering it here is what keeps the caller from having to expand identity groups itself — OpenFGA expands `team#member` and `role#assignee` usersets transitively.
|
|
18
|
-
* @summary List the instances of a resource type a subject may see
|
|
19
|
-
*/
|
|
20
|
-
export declare const resourcesControllerListVisible: (listVisibleResourcesDto: ListVisibleResourcesDto, options?: RequestInit) => Promise<VisibleResourcesDtoDataEnvelope>;
|
|
21
|
-
export declare const getResourcesControllerListRegisteredUrl: () => string;
|
|
22
|
-
/**
|
|
23
|
-
* Every registered instance of `resourceType` in the caller org, with the subjects that OWN it. Org scope is forced from the caller context.
|
|
24
|
-
*
|
|
25
|
-
* This is NOT `resource.listVisible` with a privileged subject, and the difference is the reason it exists. `listVisible` answers "what may THIS SUBJECT see"; a service needing "what has this org registered" used to ask it about a subject it had made the owner of everything — which works only for as long as that fixed owner exists, and turns any later ownership change into a silent, total loss of the enumeration. A convergence pass built on the substitute does not just stop registering: it reads every live instance as registered-but-not-live and DEREGISTERS it.
|
|
26
|
-
*
|
|
27
|
-
* A POST rather than a GET because `resource.getOwnership` is mounted at `GET /resources/:type/:id`, which would shadow any `GET /resources/registered/...` shape; the body carries the one input.
|
|
28
|
-
* @summary List the instances of a resource type this ORG has registered
|
|
29
|
-
*/
|
|
30
|
-
export declare const resourcesControllerListRegistered: (listRegisteredResourcesDto: ListRegisteredResourcesDto, options?: RequestInit) => Promise<RegisteredResourcesDtoDataEnvelope>;
|
|
31
|
-
export declare const getResourcesControllerGetOwnershipUrl: (type: string, id: string) => string;
|
|
32
|
-
/**
|
|
33
|
-
* Returns the instance visibility and the combined set of registered subjects (owners + shares; the SQL authority does not split them). 404 when the instance was never registered.
|
|
34
|
-
* @summary Read a resource instance’s current visibility + subjects
|
|
35
|
-
*/
|
|
36
|
-
export declare const resourcesControllerGetOwnership: (type: string, id: string, options?: RequestInit) => Promise<ResourceOwnershipReadDtoDataEnvelope>;
|
|
37
|
-
export declare const getResourcesControllerReplaceOwnershipUrl: (type: string, id: string) => string;
|
|
38
|
-
/**
|
|
39
|
-
* The whole post-state: after this call the instance’s registered subjects are EXACTLY `owners` ∪ `explicitShares`, and a subject named by neither loses its authority row AND its `shared_with` tuple. This is the ONLY surface that can express a revocation as part of a set write — `resource.register` upserts what it is handed and never touches a subject outside that list, so re-registering with a subject removed reports 200 and leaves both its row and its tuple live. Removals delete the tuple BEFORE the row (a crash between them leaves the subject WITHOUT access); additions write the row before the tuple. Serialised per instance by an advisory lock, so two concurrent replaces cannot interleave into a mixed set. Idempotent. Refuses (409 `RESOURCE_SUBJECT_IS_OWNER`) when a currently-registered OWNER is absent from the new `owners` list — dropping or demoting an owner is `resource.deregister`. Org scope is forced from the caller context. A body naming a `grantor` has every share judged against the level that subject actually holds (read from the tuple store, never from the body); omitting it means the calling service asserts owner authority.
|
|
40
|
-
* @summary REPLACE a resource instance’s ownership set
|
|
41
|
-
*/
|
|
42
|
-
export declare const resourcesControllerReplaceOwnership: (type: string, id: string, replaceResourceOwnershipDto: ReplaceResourceOwnershipDto, options?: RequestInit) => Promise<ResourceOwnershipDtoDataEnvelope>;
|
|
43
|
-
export declare const getResourcesControllerDeregisterUrl: (type: string, id: string) => string;
|
|
44
|
-
/**
|
|
45
|
-
* Idempotent — a no-op when the instance was never registered.
|
|
46
|
-
* @summary Deregister a resource instance (drop ownership rows + tuples)
|
|
47
|
-
*/
|
|
48
|
-
export declare const resourcesControllerDeregister: (type: string, id: string, options?: RequestInit) => Promise<void>;
|
|
49
|
-
export declare const getResourcesControllerAddShareUrl: (type: string, id: string) => string;
|
|
50
|
-
/**
|
|
51
|
-
* @summary Add an explicit share to a registered resource instance
|
|
52
|
-
*/
|
|
53
|
-
export declare const resourcesControllerAddShare: (type: string, id: string, addResourceShareDto: AddResourceShareDto, options?: RequestInit) => Promise<void>;
|
|
54
|
-
export declare const getResourcesControllerRemoveShareUrl: (type: string, id: string) => string;
|
|
55
|
-
/**
|
|
56
|
-
* The inverse of `resource.addShare`, and the ONLY way to unshare without the deregister-then-register window (during which the instance is UNREGISTERED and the PDP resolves it as a verb-only ALLOW for everyone). Drops the `shared_with` tuple FIRST and the authority row second, so a crash between them leaves the subject WITHOUT access, never with it. Idempotent: removing a share that does not exist is a no-op success. Refuses a subject that holds an `owned_by` tuple (409 `RESOURCE_SUBJECT_IS_OWNER`) — owner removal is `resource.deregister`. Does NOT change the instance visibility, even when this removes the last share: `explicit-share` with zero shares means "shared with nobody".
|
|
57
|
-
* @summary Remove an explicit share from a registered resource instance
|
|
58
|
-
*/
|
|
59
|
-
export declare const resourcesControllerRemoveShare: (type: string, id: string, removeResourceShareDto: RemoveResourceShareDto, options?: RequestInit) => Promise<void>;
|
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.resourcesControllerRemoveShare = exports.getResourcesControllerRemoveShareUrl = exports.resourcesControllerAddShare = exports.getResourcesControllerAddShareUrl = exports.resourcesControllerDeregister = exports.getResourcesControllerDeregisterUrl = exports.resourcesControllerReplaceOwnership = exports.getResourcesControllerReplaceOwnershipUrl = exports.resourcesControllerGetOwnership = exports.getResourcesControllerGetOwnershipUrl = exports.resourcesControllerListRegistered = exports.getResourcesControllerListRegisteredUrl = exports.resourcesControllerListVisible = exports.getResourcesControllerListVisibleUrl = exports.resourcesControllerRegister = exports.getResourcesControllerRegisterUrl = void 0;
|
|
4
|
-
const custom_fetch_1 = require("../../custom-fetch");
|
|
5
|
-
const getResourcesControllerRegisterUrl = () => {
|
|
6
|
-
return `/resources`;
|
|
7
|
-
};
|
|
8
|
-
exports.getResourcesControllerRegisterUrl = getResourcesControllerRegisterUrl;
|
|
9
|
-
/**
|
|
10
|
-
* Writes the ownership rows + OpenFGA tuples so the PDP ANDs the verb verdict with instance ownership. Idempotent (upsert + ignore-duplicate tuples). Org scope is forced from the caller context.
|
|
11
|
-
* @summary Register ownership/visibility of a resource instance
|
|
12
|
-
*/
|
|
13
|
-
const resourcesControllerRegister = async (registerResourceOwnershipDto, options) => {
|
|
14
|
-
return (0, custom_fetch_1.customFetch)((0, exports.getResourcesControllerRegisterUrl)(), {
|
|
15
|
-
...options,
|
|
16
|
-
method: 'POST',
|
|
17
|
-
headers: { 'Content-Type': 'application/json', ...options?.headers },
|
|
18
|
-
body: JSON.stringify(registerResourceOwnershipDto)
|
|
19
|
-
});
|
|
20
|
-
};
|
|
21
|
-
exports.resourcesControllerRegister = resourcesControllerRegister;
|
|
22
|
-
const getResourcesControllerListVisibleUrl = () => {
|
|
23
|
-
return `/resources/visible`;
|
|
24
|
-
};
|
|
25
|
-
exports.getResourcesControllerListVisibleUrl = getResourcesControllerListVisibleUrl;
|
|
26
|
-
/**
|
|
27
|
-
* Unions OpenFGA owner/shared-with visibility (usersets expanded transitively) with org-shared instances. Org scope is forced from the caller context. Used by platform BFFs to visibility-filter a list on behalf of the end user they serve.
|
|
28
|
-
*
|
|
29
|
-
* Supplying `minLevel` narrows the question from "may this subject SEE it" to "does this subject hold at least this LEVEL on it": the answer becomes owner ∪ shared at or above that rung, and org-shared instances drop out because org-shared is a visibility pattern rather than a rung. That is the question a BFF asks to decide who may MANAGE an instance, and answering it here is what keeps the caller from having to expand identity groups itself — OpenFGA expands `team#member` and `role#assignee` usersets transitively.
|
|
30
|
-
* @summary List the instances of a resource type a subject may see
|
|
31
|
-
*/
|
|
32
|
-
const resourcesControllerListVisible = async (listVisibleResourcesDto, options) => {
|
|
33
|
-
return (0, custom_fetch_1.customFetch)((0, exports.getResourcesControllerListVisibleUrl)(), {
|
|
34
|
-
...options,
|
|
35
|
-
method: 'POST',
|
|
36
|
-
headers: { 'Content-Type': 'application/json', ...options?.headers },
|
|
37
|
-
body: JSON.stringify(listVisibleResourcesDto)
|
|
38
|
-
});
|
|
39
|
-
};
|
|
40
|
-
exports.resourcesControllerListVisible = resourcesControllerListVisible;
|
|
41
|
-
const getResourcesControllerListRegisteredUrl = () => {
|
|
42
|
-
return `/resources/registered`;
|
|
43
|
-
};
|
|
44
|
-
exports.getResourcesControllerListRegisteredUrl = getResourcesControllerListRegisteredUrl;
|
|
45
|
-
/**
|
|
46
|
-
* Every registered instance of `resourceType` in the caller org, with the subjects that OWN it. Org scope is forced from the caller context.
|
|
47
|
-
*
|
|
48
|
-
* This is NOT `resource.listVisible` with a privileged subject, and the difference is the reason it exists. `listVisible` answers "what may THIS SUBJECT see"; a service needing "what has this org registered" used to ask it about a subject it had made the owner of everything — which works only for as long as that fixed owner exists, and turns any later ownership change into a silent, total loss of the enumeration. A convergence pass built on the substitute does not just stop registering: it reads every live instance as registered-but-not-live and DEREGISTERS it.
|
|
49
|
-
*
|
|
50
|
-
* A POST rather than a GET because `resource.getOwnership` is mounted at `GET /resources/:type/:id`, which would shadow any `GET /resources/registered/...` shape; the body carries the one input.
|
|
51
|
-
* @summary List the instances of a resource type this ORG has registered
|
|
52
|
-
*/
|
|
53
|
-
const resourcesControllerListRegistered = async (listRegisteredResourcesDto, options) => {
|
|
54
|
-
return (0, custom_fetch_1.customFetch)((0, exports.getResourcesControllerListRegisteredUrl)(), {
|
|
55
|
-
...options,
|
|
56
|
-
method: 'POST',
|
|
57
|
-
headers: { 'Content-Type': 'application/json', ...options?.headers },
|
|
58
|
-
body: JSON.stringify(listRegisteredResourcesDto)
|
|
59
|
-
});
|
|
60
|
-
};
|
|
61
|
-
exports.resourcesControllerListRegistered = resourcesControllerListRegistered;
|
|
62
|
-
const getResourcesControllerGetOwnershipUrl = (type, id) => {
|
|
63
|
-
return `/resources/${type}/${id}`;
|
|
64
|
-
};
|
|
65
|
-
exports.getResourcesControllerGetOwnershipUrl = getResourcesControllerGetOwnershipUrl;
|
|
66
|
-
/**
|
|
67
|
-
* Returns the instance visibility and the combined set of registered subjects (owners + shares; the SQL authority does not split them). 404 when the instance was never registered.
|
|
68
|
-
* @summary Read a resource instance’s current visibility + subjects
|
|
69
|
-
*/
|
|
70
|
-
const resourcesControllerGetOwnership = async (type, id, options) => {
|
|
71
|
-
return (0, custom_fetch_1.customFetch)((0, exports.getResourcesControllerGetOwnershipUrl)(type, id), {
|
|
72
|
-
...options,
|
|
73
|
-
method: 'GET'
|
|
74
|
-
});
|
|
75
|
-
};
|
|
76
|
-
exports.resourcesControllerGetOwnership = resourcesControllerGetOwnership;
|
|
77
|
-
const getResourcesControllerReplaceOwnershipUrl = (type, id) => {
|
|
78
|
-
return `/resources/${type}/${id}`;
|
|
79
|
-
};
|
|
80
|
-
exports.getResourcesControllerReplaceOwnershipUrl = getResourcesControllerReplaceOwnershipUrl;
|
|
81
|
-
/**
|
|
82
|
-
* The whole post-state: after this call the instance’s registered subjects are EXACTLY `owners` ∪ `explicitShares`, and a subject named by neither loses its authority row AND its `shared_with` tuple. This is the ONLY surface that can express a revocation as part of a set write — `resource.register` upserts what it is handed and never touches a subject outside that list, so re-registering with a subject removed reports 200 and leaves both its row and its tuple live. Removals delete the tuple BEFORE the row (a crash between them leaves the subject WITHOUT access); additions write the row before the tuple. Serialised per instance by an advisory lock, so two concurrent replaces cannot interleave into a mixed set. Idempotent. Refuses (409 `RESOURCE_SUBJECT_IS_OWNER`) when a currently-registered OWNER is absent from the new `owners` list — dropping or demoting an owner is `resource.deregister`. Org scope is forced from the caller context. A body naming a `grantor` has every share judged against the level that subject actually holds (read from the tuple store, never from the body); omitting it means the calling service asserts owner authority.
|
|
83
|
-
* @summary REPLACE a resource instance’s ownership set
|
|
84
|
-
*/
|
|
85
|
-
const resourcesControllerReplaceOwnership = async (type, id, replaceResourceOwnershipDto, options) => {
|
|
86
|
-
return (0, custom_fetch_1.customFetch)((0, exports.getResourcesControllerReplaceOwnershipUrl)(type, id), {
|
|
87
|
-
...options,
|
|
88
|
-
method: 'PUT',
|
|
89
|
-
headers: { 'Content-Type': 'application/json', ...options?.headers },
|
|
90
|
-
body: JSON.stringify(replaceResourceOwnershipDto)
|
|
91
|
-
});
|
|
92
|
-
};
|
|
93
|
-
exports.resourcesControllerReplaceOwnership = resourcesControllerReplaceOwnership;
|
|
94
|
-
const getResourcesControllerDeregisterUrl = (type, id) => {
|
|
95
|
-
return `/resources/${type}/${id}`;
|
|
96
|
-
};
|
|
97
|
-
exports.getResourcesControllerDeregisterUrl = getResourcesControllerDeregisterUrl;
|
|
98
|
-
/**
|
|
99
|
-
* Idempotent — a no-op when the instance was never registered.
|
|
100
|
-
* @summary Deregister a resource instance (drop ownership rows + tuples)
|
|
101
|
-
*/
|
|
102
|
-
const resourcesControllerDeregister = async (type, id, options) => {
|
|
103
|
-
return (0, custom_fetch_1.customFetch)((0, exports.getResourcesControllerDeregisterUrl)(type, id), {
|
|
104
|
-
...options,
|
|
105
|
-
method: 'DELETE'
|
|
106
|
-
});
|
|
107
|
-
};
|
|
108
|
-
exports.resourcesControllerDeregister = resourcesControllerDeregister;
|
|
109
|
-
const getResourcesControllerAddShareUrl = (type, id) => {
|
|
110
|
-
return `/resources/${type}/${id}/relationships`;
|
|
111
|
-
};
|
|
112
|
-
exports.getResourcesControllerAddShareUrl = getResourcesControllerAddShareUrl;
|
|
113
|
-
/**
|
|
114
|
-
* @summary Add an explicit share to a registered resource instance
|
|
115
|
-
*/
|
|
116
|
-
const resourcesControllerAddShare = async (type, id, addResourceShareDto, options) => {
|
|
117
|
-
return (0, custom_fetch_1.customFetch)((0, exports.getResourcesControllerAddShareUrl)(type, id), {
|
|
118
|
-
...options,
|
|
119
|
-
method: 'POST',
|
|
120
|
-
headers: { 'Content-Type': 'application/json', ...options?.headers },
|
|
121
|
-
body: JSON.stringify(addResourceShareDto)
|
|
122
|
-
});
|
|
123
|
-
};
|
|
124
|
-
exports.resourcesControllerAddShare = resourcesControllerAddShare;
|
|
125
|
-
const getResourcesControllerRemoveShareUrl = (type, id) => {
|
|
126
|
-
return `/resources/${type}/${id}/relationships`;
|
|
127
|
-
};
|
|
128
|
-
exports.getResourcesControllerRemoveShareUrl = getResourcesControllerRemoveShareUrl;
|
|
129
|
-
/**
|
|
130
|
-
* The inverse of `resource.addShare`, and the ONLY way to unshare without the deregister-then-register window (during which the instance is UNREGISTERED and the PDP resolves it as a verb-only ALLOW for everyone). Drops the `shared_with` tuple FIRST and the authority row second, so a crash between them leaves the subject WITHOUT access, never with it. Idempotent: removing a share that does not exist is a no-op success. Refuses a subject that holds an `owned_by` tuple (409 `RESOURCE_SUBJECT_IS_OWNER`) — owner removal is `resource.deregister`. Does NOT change the instance visibility, even when this removes the last share: `explicit-share` with zero shares means "shared with nobody".
|
|
131
|
-
* @summary Remove an explicit share from a registered resource instance
|
|
132
|
-
*/
|
|
133
|
-
const resourcesControllerRemoveShare = async (type, id, removeResourceShareDto, options) => {
|
|
134
|
-
return (0, custom_fetch_1.customFetch)((0, exports.getResourcesControllerRemoveShareUrl)(type, id), {
|
|
135
|
-
...options,
|
|
136
|
-
method: 'DELETE',
|
|
137
|
-
headers: { 'Content-Type': 'application/json', ...options?.headers },
|
|
138
|
-
body: JSON.stringify(removeResourceShareDto)
|
|
139
|
-
});
|
|
140
|
-
};
|
|
141
|
-
exports.resourcesControllerRemoveShare = resourcesControllerRemoveShare;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
-
* Authorization API
|
|
4
|
-
* OpenAPI spec version: 0.1.1
|
|
5
|
-
*/
|
|
6
|
-
import type { ResourceShareRefDto } from './resourceShareRefDto.js';
|
|
7
|
-
import type { ResourceSubjectRefDto } from './resourceSubjectRefDto.js';
|
|
8
|
-
export interface AddResourceShareDto {
|
|
9
|
-
share: ResourceShareRefDto;
|
|
10
|
-
/** The subject GRANTING this share, when it is not the instance owner. Used to apply the two delegation rules: a grantor may never confer more than they hold, and re-sharing is itself a level. Omitted means the caller asserts owner authority, which this service verifies against the tuple store — it is never taken on the caller's word. */
|
|
11
|
-
grantor?: ResourceSubjectRefDto;
|
|
12
|
-
}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generated by @xemahq/api-client-generator — do not edit manually.
|
|
3
|
-
* Authorization API
|
|
4
|
-
* OpenAPI spec version: 0.1.1
|
|
5
|
-
*/
|
|
6
|
-
import type { SubjectRefDto } from './subjectRefDto.js';
|
|
7
|
-
export interface AuthorizationCheckRequestDto {
|
|
8
|
-
/**
|
|
9
|
-
* Organization identifier. Scopes the grant lookup to the tenant.
|
|
10
|
-
* @minLength 1
|
|
11
|
-
*/
|
|
12
|
-
orgId: string;
|
|
13
|
-
/**
|
|
14
|
-
* Canonical CapabilityRef `<domain>:<resource>.<verb>@<major>` from `@xemahq/kernel-contracts/capability`.
|
|
15
|
-
* @minLength 1
|
|
16
|
-
*/
|
|
17
|
-
capability: string;
|
|
18
|
-
subject: SubjectRefDto;
|
|
19
|
-
/**
|
|
20
|
-
* ExecutionEnvironmentRef in `environment:<slug>` format (e.g. `"environment:project"`). The service parses the prefix and checks the slug against the ExecutionEnvironmentKind enum.
|
|
21
|
-
* @minLength 1
|
|
22
|
-
*/
|
|
23
|
-
environment: string;
|
|
24
|
-
/**
|
|
25
|
-
* Canonical `xema://<Space>/resource/<type>/<id>[@version]` address naming the instance the capability targets. Optional — omit it for a verb-only check; do not send a placeholder. The legacy `resource:<type>:<id>` form is still accepted, but it cannot express the org scope the canonical form carries. Any other shape is refused at the edge with `400 RESOURCE_REF_MALFORMED`.
|
|
26
|
-
* @minLength 1
|
|
27
|
-
*/
|
|
28
|
-
resource?: string;
|
|
29
|
-
/**
|
|
30
|
-
* Audience policy slug; Phase 3 ignores this dimension.
|
|
31
|
-
* @minLength 1
|
|
32
|
-
*/
|
|
33
|
-
audience?: string;
|
|
34
|
-
/**
|
|
35
|
-
* Caller-supplied correlation id surfaced in audit logs.
|
|
36
|
-
* @minLength 1
|
|
37
|
-
*/
|
|
38
|
-
correlationId?: string;
|
|
39
|
-
}
|