azure-devops-extension-api 4.254.0 → 4.256.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/AdvancedSecurity.Reporting/Reporting.d.ts +8 -0
- package/Contributions/Contributions.d.ts +4 -0
- package/ExtensionManagement/ExtensionManagement.d.ts +4 -0
- package/Git/Git.d.ts +21 -0
- package/Git/Git.js +14 -0
- package/Git/Git.min.js +1 -1
- package/Git/GitClient.js +6 -6
- package/Git/GitClient.min.js +1 -1
- package/Locations/LocationsClient.d.ts +6 -0
- package/Locations/LocationsClient.js +24 -0
- package/Locations/LocationsClient.min.js +1 -1
- package/Management/Management.d.ts +76 -153
- package/Management/Management.js +10 -2
- package/Management/Management.min.js +1 -1
- package/Management/ManagementClient.d.ts +20 -134
- package/Management/ManagementClient.js +54 -419
- package/Management/ManagementClient.min.js +1 -1
- package/Pipelines/Pipelines.d.ts +1 -0
- package/Pipelines/Pipelines.js +1 -0
- package/Pipelines/Pipelines.min.js +1 -1
- package/Release/ReleaseClient.d.ts +2 -1
- package/Release/ReleaseClient.js +7 -1
- package/Release/ReleaseClient.min.js +1 -1
- package/ServiceEndpoint/ServiceEndpoint.d.ts +1 -1
- package/ServiceEndpoint/ServiceEndpointClient.d.ts +7 -0
- package/ServiceEndpoint/ServiceEndpointClient.js +22 -0
- package/ServiceEndpoint/ServiceEndpointClient.min.js +1 -1
- package/TaskAgent/TaskAgent.d.ts +18 -1
- package/TaskAgent/TaskAgent.js +1 -0
- package/TaskAgent/TaskAgent.min.js +1 -1
- package/TaskAgent/TaskAgentClient.js +4 -4
- package/TaskAgent/TaskAgentClient.min.js +1 -1
- package/TestPlan/TestPlan.d.ts +41 -6
- package/Tfvc/Tfvc.d.ts +4 -0
- package/WebApi/WebApi.d.ts +0 -13
- package/WebApi/WebApi.js +0 -15
- package/WebApi/WebApi.min.js +1 -1
- package/_manifest/spdx_2.2/ESRPClientLogs0712000053233.json +1 -0
- package/_manifest/spdx_2.2/bsi.cose +0 -0
- package/_manifest/spdx_2.2/bsi.json +1 -0
- package/_manifest/spdx_2.2/manifest.cat +0 -0
- package/_manifest/spdx_2.2/manifest.spdx.cose +0 -0
- package/_manifest/spdx_2.2/manifest.spdx.json +9799 -0
- package/_manifest/spdx_2.2/manifest.spdx.json.sha256 +1 -0
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
var __extends=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])};return function(t,r){function i(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(i.prototype=r.prototype,new i)}}(),__awaiter=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))(function(n,o){function a(e){try{s(i.next(e))}catch(e){o(e)}}function u(e){try{s(i.throw(e))}catch(e){o(e)}}function s(e){e.done?n(e.value):new r(function(t){t(e.value)}).then(a,u)}s((i=i.apply(e,t||[])).next())})},__generator=this&&this.__generator||function(e,t){function r(r){return function(a){return function(r){if(i)throw new TypeError("Generator is already executing.");for(;u;)try{if(i=1,n&&(o=2&r[0]?n.return:r[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,r[1])).done)return o;switch(n=0,o&&(r=[2&r[0],o.value]),r[0]){case 0:case 1:o=r;break;case 4:return u.label++,{value:r[1],done:!1};case 5:u.label++,n=r[1],r=[0];continue;case 7:r=u.ops.pop(),u.trys.pop();continue;default:if(o=u.trys,!(o=o.length>0&&o[o.length-1])&&(6===r[0]||2===r[0])){u=0;continue}if(3===r[0]&&(!o||r[1]>o[0]&&r[1]<o[3])){u.label=r[1];break}if(6===r[0]&&u.label<o[1]){u.label=o[1],o=r;break}if(o&&u.label<o[2]){u.label=o[2],u.ops.push(r);break}o[2]&&u.ops.pop(),u.trys.pop();continue}r=t.call(e,u)}catch(e){r=[6,e],n=0}finally{i=o=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,a])}}var i,n,o,a,u={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:r(0),throw:r(1),return:r(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a};define(["require","exports","../Common/RestClientBase"],function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(t){return e.call(this,t)||this}return __extends(t,e),t.prototype.getConnectionData=function(e,t,r){return __awaiter(this,void 0,void 0,function(){var i;return __generator(this,function(n){return i={connectOptions:e,lastChangeId:t,lastChangeId64:r},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ConnectionData",queryParams:i})]})})},t.prototype.getResourceArea=function(e,t,r,i){return __awaiter(this,void 0,void 0,function(){var n;return __generator(this,function(o){return n={enterpriseName:t,organizationName:r,accessMapping:i},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",routeValues:{areaId:e},queryParams:n})]})})},t.prototype.getResourceAreaByHost=function(e,t,r){return __awaiter(this,void 0,void 0,function(){var i;return __generator(this,function(n){return i={hostId:t,accessMapping:r},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",routeValues:{areaId:e},queryParams:i})]})})},t.prototype.getResourceAreas=function(e,t){return __awaiter(this,void 0,void 0,function(){var r;return __generator(this,function(i){return r={enterpriseName:e,organizationName:t},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",queryParams:r})]})})},t.prototype.getResourceAreasByHost=function(e){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(r){return t={hostId:e},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",queryParams:t})]})})},t.prototype.deleteServiceDefinition=function(e,t){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(r){return[2,this.beginRequest({apiVersion:"7.2-preview.1",method:"DELETE",routeTemplate:"_apis/ServiceDefinitions/{serviceType}/{identifier}",routeValues:{serviceType:e,identifier:t}})]})})},t.prototype.getServiceDefinition=function(e,t,r,i){return __awaiter(this,void 0,void 0,function(){var n;return __generator(this,function(o){return n={allowFaultIn:r,previewFaultIn:i},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ServiceDefinitions/{serviceType}/{identifier}",routeValues:{serviceType:e,identifier:t},queryParams:n})]})})},t.prototype.getServiceDefinitions=function(e){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(t){return[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ServiceDefinitions/{serviceType}/{identifier}",routeValues:{serviceType:e}})]})})},t.prototype.updateServiceDefinitions=function(e){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(t){return[2,this.beginRequest({apiVersion:"7.2-preview.1",method:"PATCH",routeTemplate:"_apis/ServiceDefinitions/{serviceType}/{identifier}",body:e})]})})},t}(r.RestClientBase);t.LocationsRestClient=i});
|
|
1
|
+
var __extends=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])};return function(t,r){function i(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(i.prototype=r.prototype,new i)}}(),__awaiter=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))(function(n,o){function a(e){try{s(i.next(e))}catch(e){o(e)}}function u(e){try{s(i.throw(e))}catch(e){o(e)}}function s(e){e.done?n(e.value):new r(function(t){t(e.value)}).then(a,u)}s((i=i.apply(e,t||[])).next())})},__generator=this&&this.__generator||function(e,t){function r(r){return function(a){return function(r){if(i)throw new TypeError("Generator is already executing.");for(;u;)try{if(i=1,n&&(o=2&r[0]?n.return:r[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,r[1])).done)return o;switch(n=0,o&&(r=[2&r[0],o.value]),r[0]){case 0:case 1:o=r;break;case 4:return u.label++,{value:r[1],done:!1};case 5:u.label++,n=r[1],r=[0];continue;case 7:r=u.ops.pop(),u.trys.pop();continue;default:if(o=u.trys,!(o=o.length>0&&o[o.length-1])&&(6===r[0]||2===r[0])){u=0;continue}if(3===r[0]&&(!o||r[1]>o[0]&&r[1]<o[3])){u.label=r[1];break}if(6===r[0]&&u.label<o[1]){u.label=o[1],o=r;break}if(o&&u.label<o[2]){u.label=o[2],u.ops.push(r);break}o[2]&&u.ops.pop(),u.trys.pop();continue}r=t.call(e,u)}catch(e){r=[6,e],n=0}finally{i=o=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,a])}}var i,n,o,a,u={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:r(0),throw:r(1),return:r(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a};define(["require","exports","../Common/RestClientBase"],function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(e){function t(t){return e.call(this,t)||this}return __extends(t,e),t.prototype.getConnectionData=function(e,t,r){return __awaiter(this,void 0,void 0,function(){var i;return __generator(this,function(n){return i={connectOptions:e,lastChangeId:t,lastChangeId64:r},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ConnectionData",queryParams:i})]})})},t.prototype.getResourceArea=function(e,t,r,i){return __awaiter(this,void 0,void 0,function(){var n;return __generator(this,function(o){return n={enterpriseName:t,organizationName:r,accessMapping:i},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",routeValues:{areaId:e},queryParams:n})]})})},t.prototype.getResourceAreaByHost=function(e,t,r){return __awaiter(this,void 0,void 0,function(){var i;return __generator(this,function(n){return i={hostId:t,accessMapping:r},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",routeValues:{areaId:e},queryParams:i})]})})},t.prototype.getResourceAreaByInstanceId=function(e,t,r){return __awaiter(this,void 0,void 0,function(){var i;return __generator(this,function(n){return i={instanceId:t,accessMapping:r},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",routeValues:{areaId:e},queryParams:i})]})})},t.prototype.getResourceAreas=function(e,t){return __awaiter(this,void 0,void 0,function(){var r;return __generator(this,function(i){return r={enterpriseName:e,organizationName:t},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",queryParams:r})]})})},t.prototype.getResourceAreasByHost=function(e){return __awaiter(this,void 0,void 0,function(){var t;return __generator(this,function(r){return t={hostId:e},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ResourceAreas/{areaId}",queryParams:t})]})})},t.prototype.deleteServiceDefinition=function(e,t){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(r){return[2,this.beginRequest({apiVersion:"7.2-preview.1",method:"DELETE",routeTemplate:"_apis/ServiceDefinitions/{serviceType}/{identifier}",routeValues:{serviceType:e,identifier:t}})]})})},t.prototype.getServiceDefinition=function(e,t,r,i){return __awaiter(this,void 0,void 0,function(){var n;return __generator(this,function(o){return n={allowFaultIn:r,previewFaultIn:i},[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ServiceDefinitions/{serviceType}/{identifier}",routeValues:{serviceType:e,identifier:t},queryParams:n})]})})},t.prototype.getServiceDefinitions=function(e){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(t){return[2,this.beginRequest({apiVersion:"7.2-preview.1",routeTemplate:"_apis/ServiceDefinitions/{serviceType}/{identifier}",routeValues:{serviceType:e}})]})})},t.prototype.updateServiceDefinitions=function(e){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(t){return[2,this.beginRequest({apiVersion:"7.2-preview.1",method:"PATCH",routeTemplate:"_apis/ServiceDefinitions/{serviceType}/{identifier}",body:e})]})})},t}(r.RestClientBase);t.LocationsRestClient=i});
|
|
@@ -1,61 +1,4 @@
|
|
|
1
1
|
import * as WebApi from "../WebApi/WebApi";
|
|
2
|
-
export interface AdvSecEnablementFeatures {
|
|
3
|
-
/**
|
|
4
|
-
* Auto enablement of AdvSec for new projects or repos will be enabled when set to true and will be unchanged when set to false.
|
|
5
|
-
*/
|
|
6
|
-
autoEnableNewProjectOrRepos: boolean;
|
|
7
|
-
/**
|
|
8
|
-
* CodeQL enablement status set to False when disabled and True when enabled; Null is never explicitly set.
|
|
9
|
-
*/
|
|
10
|
-
codeQLEnabled: boolean;
|
|
11
|
-
/**
|
|
12
|
-
* Dependabot enablement status set to False when disabled and True when enabled; Null is never explicitly set. \<br /\>When true, Dependabot will open PRs to support security updates for outdated dependencies. \<br /\>Setting Dependabot enablement state is only supported for repo enablement and not org or project enablement at this time.
|
|
13
|
-
*/
|
|
14
|
-
dependabotEnabled: boolean;
|
|
15
|
-
/**
|
|
16
|
-
* Dependency Scanning Injection enablement status set to False when disabled and True when enabled; Null is never explicitly set. \<br /\> If Advanced Security is NOT already enabled, behavior will depend on if Advanced Security is to be enabled/disabled. DependencyScanningInjectionEnabled will not affect anything in this scenario. \<br /\> If Advanced Security is to be disabled, the value of DependencyScanningInjectionEnabled will have no effect. \<br /\> Setting Dependency Scanning enablement state is only supported for repo enablement and not org or project enablement at this time.
|
|
17
|
-
*/
|
|
18
|
-
dependencyScanningInjectionEnabled: boolean;
|
|
19
|
-
/**
|
|
20
|
-
* ForceRepoSecretScanning will be set to true when Enabled, false when Disabled, and null when not set. \<br /\> If GHAzDO is NOT already enabled, behavior will depend on if GHAzDO is to be enabled/disabled. ForceRepoSecretScanning will not affect anything in this scenario. \<br /\> If GHAzDO is to be disabled, the value of ForceRepoSecretScan will have no effect. \<br /\> If GHAzDO is to be enabled for the first time on a repo, then ForceRepoSecretScanning will have no effect. \<br /\> If GHAzDO is to be enabled and the repo is already enabled, then ForceRepoSecretScanning will force the secret scanning job to be run if it is set to true. \<br /\> In all cases where ForceRepoSecretScanning is not expected to affect behavior, it will be set to false before being sent to Tfs.
|
|
21
|
-
*/
|
|
22
|
-
forceRepoSecretScanning: boolean;
|
|
23
|
-
}
|
|
24
|
-
export interface AdvSecEnablementSettings {
|
|
25
|
-
/**
|
|
26
|
-
* Automatically enable Advanced Security on newly created repositories.
|
|
27
|
-
*/
|
|
28
|
-
enableOnCreate: boolean;
|
|
29
|
-
reposEnablementStatus: AdvSecEnablementStatus[];
|
|
30
|
-
}
|
|
31
|
-
export interface AdvSecEnablementSettingsUpdate extends AdvSecEnablementStatusUpdate {
|
|
32
|
-
/**
|
|
33
|
-
* Automatically enable Advanced Security on newly created repositories.
|
|
34
|
-
*/
|
|
35
|
-
enableOnCreate: boolean;
|
|
36
|
-
}
|
|
37
|
-
export interface AdvSecEnablementStatus extends AdvSecEnablementStatusUpdate {
|
|
38
|
-
/**
|
|
39
|
-
* The last time the status of Advanced Security for this repository was updated
|
|
40
|
-
*/
|
|
41
|
-
advSecEnablementLastChangedDate: Date;
|
|
42
|
-
projectId: string;
|
|
43
|
-
repositoryId: string;
|
|
44
|
-
}
|
|
45
|
-
export interface AdvSecEnablementStatusUpdate {
|
|
46
|
-
/**
|
|
47
|
-
* Advanced Security enablement status set to False when disabled and True when enabled; Null is never explicitly set.
|
|
48
|
-
*/
|
|
49
|
-
advSecEnabled: boolean;
|
|
50
|
-
/**
|
|
51
|
-
* Includes additional features that can be enabled alongside Advanced Security.
|
|
52
|
-
*/
|
|
53
|
-
advSecEnablementFeatures: AdvSecEnablementFeatures;
|
|
54
|
-
/**
|
|
55
|
-
* When true, pushes containing secrets will be blocked. \<br /\>When false, pushes are scanned for secrets and are not blocked. \<br /\>If includeAllProperties in the request is false, this value will be null.
|
|
56
|
-
*/
|
|
57
|
-
blockPushes: boolean;
|
|
58
|
-
}
|
|
59
2
|
/**
|
|
60
3
|
* Billable Committers Details for Advanced Security Services
|
|
61
4
|
*/
|
|
@@ -143,11 +86,23 @@ export interface BilledCommittersList {
|
|
|
143
86
|
*/
|
|
144
87
|
uniqueCommitterCount: number;
|
|
145
88
|
}
|
|
146
|
-
export interface
|
|
89
|
+
export interface CodeSecurityFeatures {
|
|
147
90
|
/**
|
|
148
91
|
* CodeQL enablement status set to False when disabled and True when enabled; Null is never explicitly set.
|
|
149
92
|
*/
|
|
150
93
|
codeQLEnabled: boolean;
|
|
94
|
+
/**
|
|
95
|
+
* The VSID of the last user who modified the enablement status of Code Security.
|
|
96
|
+
*/
|
|
97
|
+
codeSecurityChangedBy: string;
|
|
98
|
+
/**
|
|
99
|
+
* Code Security enablement status set to False when disabled and True when enabled; Null is never explicitly set.
|
|
100
|
+
*/
|
|
101
|
+
codeSecurityEnabled: boolean;
|
|
102
|
+
/**
|
|
103
|
+
* The last time the status of Code Security for this repository was updated
|
|
104
|
+
*/
|
|
105
|
+
codeSecurityEnablementLastChangedDate: Date;
|
|
151
106
|
/**
|
|
152
107
|
* Dependabot enablement status set to False when disabled and True when enabled; Null is never explicitly set. \<br /\>When true, Dependabot will open PRs to support security updates for outdated dependencies. \<br /\>Setting Dependabot enablement state is only supported for repo enablement and not org or project enablement at this time.
|
|
153
108
|
*/
|
|
@@ -159,144 +114,112 @@ export interface CodeScanningFeatures {
|
|
|
159
114
|
}
|
|
160
115
|
export interface EnablementOnCreateSettings {
|
|
161
116
|
/**
|
|
162
|
-
* Automatically enable Code
|
|
117
|
+
* Automatically enable Code Security on newly created repositories.
|
|
163
118
|
*/
|
|
164
|
-
|
|
119
|
+
enableCodeSecurityOnCreate: boolean;
|
|
165
120
|
/**
|
|
166
|
-
* Automatically enable Secret
|
|
121
|
+
* Automatically enable Secret Protection on newly created repositories.
|
|
167
122
|
*/
|
|
168
|
-
|
|
123
|
+
enableSecretProtectionOnCreate: boolean;
|
|
169
124
|
}
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
codeScanningEnabled: boolean;
|
|
175
|
-
/**
|
|
176
|
-
* Includes code scanning features that can be enabled.
|
|
177
|
-
*/
|
|
178
|
-
codeScanningFeatures: CodeScanningFeatures;
|
|
179
|
-
/**
|
|
180
|
-
* Auto enablement setting for newly created repositories.
|
|
181
|
-
*/
|
|
182
|
-
enablementOnCreateSettings: EnablementOnCreateSettings;
|
|
183
|
-
/**
|
|
184
|
-
* A list of enablement statuses for repositories within the specified organization or project.
|
|
185
|
-
*/
|
|
186
|
-
reposEnablementStatus: RepoEnablementSettings[];
|
|
125
|
+
/**
|
|
126
|
+
* Information related to meter usage estimate for Code Security plan and/or Secret Protection plan
|
|
127
|
+
*/
|
|
128
|
+
export interface MeterUsageEstimate {
|
|
187
129
|
/**
|
|
188
|
-
*
|
|
130
|
+
* Meter usage estimate when enabling Code Security plan
|
|
189
131
|
*/
|
|
190
|
-
|
|
132
|
+
codeSecurityMeterUsageEstimate: BilledCommittersList;
|
|
191
133
|
/**
|
|
192
|
-
*
|
|
134
|
+
* Meter usage estimate when enabling Secret Protection plan
|
|
193
135
|
*/
|
|
194
|
-
|
|
136
|
+
secretProtectionMeterUsageEstimate: BilledCommittersList;
|
|
195
137
|
}
|
|
196
138
|
/**
|
|
197
|
-
* Information related to
|
|
139
|
+
* Information related to meter usage for a Scanning plan
|
|
198
140
|
*/
|
|
199
|
-
export interface
|
|
141
|
+
export interface MeterUsageForPlan {
|
|
200
142
|
/**
|
|
201
143
|
* The Azure DevOps account
|
|
202
144
|
*/
|
|
203
145
|
accountId: string;
|
|
204
146
|
azureSubscriptionId: string;
|
|
205
147
|
/**
|
|
206
|
-
*
|
|
207
|
-
*/
|
|
208
|
-
billedCommitters: string[];
|
|
209
|
-
/**
|
|
210
|
-
* A list of BilledCommitter objects that contain the identityRef of committers that have AdvSec enabled
|
|
148
|
+
* The identityRef of committers that contributed to repositories with Scanning plan enabled
|
|
211
149
|
*/
|
|
212
|
-
billedUsers:
|
|
150
|
+
billedUsers: BilledCommittersList;
|
|
213
151
|
/**
|
|
214
152
|
* The date this billing information pertains to
|
|
215
153
|
*/
|
|
216
154
|
billingDate: Date;
|
|
217
155
|
/**
|
|
218
|
-
* True when
|
|
219
|
-
*/
|
|
220
|
-
isAdvSecBillable: boolean;
|
|
221
|
-
/**
|
|
222
|
-
* True when Advanced Security features are enabled in this organization
|
|
156
|
+
* True when the Scanning plan is enabled in this organization
|
|
223
157
|
*/
|
|
224
|
-
|
|
158
|
+
isPlanEnabled: boolean;
|
|
225
159
|
/**
|
|
226
160
|
* The Azure subscription
|
|
227
161
|
*/
|
|
228
162
|
tenantId: string;
|
|
163
|
+
}
|
|
164
|
+
export interface OrgEnablementSettings {
|
|
229
165
|
/**
|
|
230
|
-
*
|
|
166
|
+
* Includes code security features that can be enabled.
|
|
231
167
|
*/
|
|
232
|
-
|
|
233
|
-
}
|
|
234
|
-
/**
|
|
235
|
-
* Information related to meter usage estimate for Code Scanning and Secret Scanning
|
|
236
|
-
*/
|
|
237
|
-
export interface MeterUsageEstimate {
|
|
168
|
+
codeSecurityFeatures: CodeSecurityFeatures;
|
|
238
169
|
/**
|
|
239
|
-
*
|
|
170
|
+
* Auto enablement setting for newly created repositories.
|
|
240
171
|
*/
|
|
241
|
-
|
|
172
|
+
enablementOnCreateSettings: EnablementOnCreateSettings;
|
|
242
173
|
/**
|
|
243
|
-
*
|
|
174
|
+
* A list of enablement statuses for repositories within the specified organization or project.
|
|
244
175
|
*/
|
|
245
|
-
|
|
246
|
-
}
|
|
247
|
-
/**
|
|
248
|
-
* Information related to meter usage for a Scanning plan
|
|
249
|
-
*/
|
|
250
|
-
export interface MeterUsageForPlan {
|
|
176
|
+
reposEnablementStatus: RepoEnablementSettings[];
|
|
251
177
|
/**
|
|
252
|
-
*
|
|
178
|
+
* Includes secret protection features that can be enabled.
|
|
253
179
|
*/
|
|
254
|
-
|
|
255
|
-
|
|
180
|
+
secretProtectionFeatures: SecretProtectionFeatures;
|
|
181
|
+
}
|
|
182
|
+
export declare enum Plan {
|
|
256
183
|
/**
|
|
257
|
-
*
|
|
184
|
+
* No plan is indicated
|
|
258
185
|
*/
|
|
259
|
-
|
|
186
|
+
None = 0,
|
|
260
187
|
/**
|
|
261
|
-
* The
|
|
188
|
+
* The Code Security plan
|
|
262
189
|
*/
|
|
263
|
-
|
|
190
|
+
CodeSecurity = 1,
|
|
264
191
|
/**
|
|
265
|
-
*
|
|
192
|
+
* The Secret Protection plan
|
|
266
193
|
*/
|
|
267
|
-
|
|
194
|
+
SecretProtection = 2,
|
|
268
195
|
/**
|
|
269
|
-
*
|
|
196
|
+
* Include all plans
|
|
270
197
|
*/
|
|
271
|
-
|
|
198
|
+
All = 3
|
|
272
199
|
}
|
|
273
|
-
export interface
|
|
274
|
-
}
|
|
275
|
-
export declare enum Plan {
|
|
200
|
+
export interface ProjectEnablementSettings {
|
|
276
201
|
/**
|
|
277
|
-
*
|
|
202
|
+
* Includes code security features that can be enabled.
|
|
278
203
|
*/
|
|
279
|
-
|
|
204
|
+
codeSecurityFeatures: CodeSecurityFeatures;
|
|
280
205
|
/**
|
|
281
|
-
*
|
|
206
|
+
* Auto enablement setting for newly created repositories.
|
|
282
207
|
*/
|
|
283
|
-
|
|
284
|
-
}
|
|
285
|
-
export interface ProjectEnablementSettings extends EnablementSettings {
|
|
286
|
-
}
|
|
287
|
-
export interface RepoEnablementSettings {
|
|
208
|
+
enablementOnCreateSettings: EnablementOnCreateSettings;
|
|
288
209
|
/**
|
|
289
|
-
*
|
|
210
|
+
* A list of enablement statuses for repositories within the specified organization or project.
|
|
290
211
|
*/
|
|
291
|
-
|
|
212
|
+
reposEnablementStatus: RepoEnablementSettings[];
|
|
292
213
|
/**
|
|
293
|
-
*
|
|
214
|
+
* Includes secret protection features that can be enabled.
|
|
294
215
|
*/
|
|
295
|
-
|
|
216
|
+
secretProtectionFeatures: SecretProtectionFeatures;
|
|
217
|
+
}
|
|
218
|
+
export interface RepoEnablementSettings {
|
|
296
219
|
/**
|
|
297
|
-
* Includes
|
|
220
|
+
* Includes Code Security features that can be enabled.
|
|
298
221
|
*/
|
|
299
|
-
|
|
222
|
+
codeSecurityFeatures: CodeSecurityFeatures;
|
|
300
223
|
/**
|
|
301
224
|
* Indicates whether the repository is part of the bundled SKU (old billing plan) or unbundled SKUs (new billing plan).
|
|
302
225
|
*/
|
|
@@ -310,25 +233,25 @@ export interface RepoEnablementSettings {
|
|
|
310
233
|
*/
|
|
311
234
|
repositoryId: string;
|
|
312
235
|
/**
|
|
313
|
-
* Secret
|
|
236
|
+
* Includes Secret Protection features that can be enabled.
|
|
314
237
|
*/
|
|
315
|
-
|
|
238
|
+
secretProtectionFeatures: SecretProtectionFeatures;
|
|
239
|
+
}
|
|
240
|
+
export interface SecretProtectionFeatures {
|
|
316
241
|
/**
|
|
317
|
-
*
|
|
242
|
+
* When true, pushes containing secrets will be blocked. \<br /\>When false, pushes are scanned for secrets and are not blocked. \<br /\>If includeAllProperties in the request is false, this value will be null.
|
|
318
243
|
*/
|
|
319
|
-
|
|
244
|
+
blockPushes: boolean;
|
|
320
245
|
/**
|
|
321
|
-
*
|
|
246
|
+
* The VSID of the last user who modified the enablement status of Secret Protection.
|
|
322
247
|
*/
|
|
323
|
-
|
|
324
|
-
}
|
|
325
|
-
export interface SecretScanningFeatures {
|
|
248
|
+
secretProtectionChangedBy: string;
|
|
326
249
|
/**
|
|
327
|
-
*
|
|
250
|
+
* Secret Protection enablement status set to False when disabled and True when enabled; Null is never explicitly set.
|
|
328
251
|
*/
|
|
329
|
-
|
|
252
|
+
secretProtectionEnabled: boolean;
|
|
330
253
|
/**
|
|
331
|
-
*
|
|
254
|
+
* The last time the status of Secret Protection for this repository was updated
|
|
332
255
|
*/
|
|
333
|
-
|
|
256
|
+
secretProtectionEnablementLastChangedDate: Date;
|
|
334
257
|
}
|
package/Management/Management.js
CHANGED
|
@@ -8,13 +8,21 @@ define(["require", "exports"], function (require, exports) {
|
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
9
|
var Plan;
|
|
10
10
|
(function (Plan) {
|
|
11
|
+
/**
|
|
12
|
+
* No plan is indicated
|
|
13
|
+
*/
|
|
14
|
+
Plan[Plan["None"] = 0] = "None";
|
|
11
15
|
/**
|
|
12
16
|
* The Code Security plan
|
|
13
17
|
*/
|
|
14
|
-
Plan[Plan["CodeSecurity"] =
|
|
18
|
+
Plan[Plan["CodeSecurity"] = 1] = "CodeSecurity";
|
|
15
19
|
/**
|
|
16
20
|
* The Secret Protection plan
|
|
17
21
|
*/
|
|
18
|
-
Plan[Plan["SecretProtection"] =
|
|
22
|
+
Plan[Plan["SecretProtection"] = 2] = "SecretProtection";
|
|
23
|
+
/**
|
|
24
|
+
* Include all plans
|
|
25
|
+
*/
|
|
26
|
+
Plan[Plan["All"] = 3] = "All";
|
|
19
27
|
})(Plan = exports.Plan || (exports.Plan = {}));
|
|
20
28
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
define(["require","exports"],function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});!function(e){e[e.
|
|
1
|
+
define(["require","exports"],function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});!function(e){e[e.None=0]="None",e[e.CodeSecurity=1]="CodeSecurity",e[e.SecretProtection=2]="SecretProtection",e[e.All=3]="All"}(t.Plan||(t.Plan={}))});
|
|
@@ -3,206 +3,92 @@ import { RestClientBase } from "../Common/RestClientBase";
|
|
|
3
3
|
import * as Management from "../Management/Management";
|
|
4
4
|
export declare class ManagementRestClient extends RestClientBase {
|
|
5
5
|
constructor(options: IVssRestClientOptions);
|
|
6
|
-
/**
|
|
7
|
-
* Determine if Advanced Security is enabled for a repository
|
|
8
|
-
*
|
|
9
|
-
* @param project - Project ID or project name
|
|
10
|
-
* @param repository - The name or ID of the repository
|
|
11
|
-
* @param includeAllProperties - When true, will also determine if pushes are blocked when secrets are detected
|
|
12
|
-
*/
|
|
13
|
-
getRepoEnablementStatus2(project: string, repository: string, includeAllProperties?: boolean): Promise<Management.RepoEnablementSettings>;
|
|
14
|
-
/**
|
|
15
|
-
* Update the enablement of Advanced Security for a repository
|
|
16
|
-
*
|
|
17
|
-
* @param savedAdvSecEnablementStatus - new status
|
|
18
|
-
* @param project - Project ID or project name
|
|
19
|
-
* @param repository - Name or ID of the repository
|
|
20
|
-
*/
|
|
21
|
-
updateRepoAdvSecEnablementStatus2(savedAdvSecEnablementStatus: Management.RepoEnablementSettings, project: string, repository: string): Promise<void>;
|
|
22
|
-
/**
|
|
23
|
-
* During multi-org billing computation in primary scale unit(EUS21), this API is used to create billing snapshot for a specific org. Primary scale unit will call this API for each org in different scsle units to create billing snapshot. Data will be stored in the org specific partition DB -\> billing snapshot table. This is needed as customers will fetch billing data from their org specific partition DB.
|
|
24
|
-
*
|
|
25
|
-
* @param meterUsage -
|
|
26
|
-
*/
|
|
27
|
-
createBillingSnapshot(meterUsage: Management.MeterUsage): Promise<void>;
|
|
28
|
-
/**
|
|
29
|
-
* Get all billable committers details, including those not matched with a VSID.
|
|
30
|
-
*
|
|
31
|
-
* @param billingDate - The date to query, or if not provided, today
|
|
32
|
-
*/
|
|
33
|
-
getBillableCommitterDetails(billingDate?: Date): Promise<Management.BillableCommitterDetails[]>;
|
|
34
|
-
/**
|
|
35
|
-
*/
|
|
36
|
-
getLastMeterUsage(): Promise<Management.MeterUsage>;
|
|
37
|
-
/**
|
|
38
|
-
* Get commiters used when calculating billing information.
|
|
39
|
-
*
|
|
40
|
-
* @param billingDate - The date to query, or if not provided, today
|
|
41
|
-
*/
|
|
42
|
-
getMeterUsage(billingDate?: Date): Promise<Management.MeterUsage>;
|
|
43
6
|
/**
|
|
44
7
|
* During multi-org billing computation in primary scale unit(EUS21), this API is used to create billing snapshot for a specific org. Primary scale unit will call this API for each org in different scsle units to create billing snapshot. Data will be stored in the org specific partition DB -\> billing snapshot table. This is needed as customers will fetch billing data from their org specific partition DB.
|
|
45
8
|
*
|
|
46
9
|
* @param meterUsage -
|
|
47
10
|
* @param plan -
|
|
48
11
|
*/
|
|
49
|
-
|
|
12
|
+
createBillingSnapshot3(meterUsage: Management.MeterUsageForPlan, plan: Management.Plan): Promise<void>;
|
|
50
13
|
/**
|
|
51
14
|
* Get all billable committers details, including those not matched with a VSID.
|
|
52
15
|
*
|
|
53
16
|
* @param plan - The plan to query. Plans supported: CodeSecurity and SecretProtection. This is a mandatory parameter.
|
|
54
17
|
* @param billingDate - The date to query, or if not provided, today
|
|
55
18
|
*/
|
|
56
|
-
|
|
19
|
+
getBillableCommitterDetails3(plan: Management.Plan, billingDate?: Date): Promise<Management.BillableCommitterDetails[]>;
|
|
57
20
|
/**
|
|
58
21
|
* @param plan -
|
|
59
22
|
*/
|
|
60
|
-
|
|
23
|
+
getLastMeterUsage3(plan: Management.Plan): Promise<Management.MeterUsageForPlan>;
|
|
61
24
|
/**
|
|
62
25
|
* Get commiters used when calculating billing information.
|
|
63
26
|
*
|
|
64
27
|
* @param plan - The plan to query. Plans supported: CodeSecurity and SecretProtection. This is a mandatory parameter.
|
|
65
28
|
* @param billingDate - The date to query, or if not provided, today
|
|
66
29
|
*/
|
|
67
|
-
|
|
68
|
-
/**
|
|
69
|
-
* Get the current status of Advanced Security for the organization
|
|
70
|
-
*
|
|
71
|
-
* @param includeAllProperties - When true, also determine if pushes are blocked if they contain secrets
|
|
72
|
-
*/
|
|
73
|
-
getOrgEnablementStatus(includeAllProperties?: boolean): Promise<Management.AdvSecEnablementSettings>;
|
|
74
|
-
/**
|
|
75
|
-
* Update the status of Advanced Security for the organization
|
|
76
|
-
*
|
|
77
|
-
* @param savedAdvSecEnablementStatus - The new status
|
|
78
|
-
*/
|
|
79
|
-
updateOrgEnablementStatus(savedAdvSecEnablementStatus: Management.AdvSecEnablementSettingsUpdate): Promise<void>;
|
|
30
|
+
getMeterUsage3(plan: Management.Plan, billingDate?: Date): Promise<Management.MeterUsageForPlan>;
|
|
80
31
|
/**
|
|
81
32
|
* Get the current status of Advanced Security for the organization
|
|
82
33
|
*
|
|
83
34
|
* @param includeAllProperties - When true, also determine if pushes are blocked if they contain secrets
|
|
84
35
|
*/
|
|
85
|
-
|
|
36
|
+
getOrgEnablementStatus3(includeAllProperties?: boolean): Promise<Management.OrgEnablementSettings>;
|
|
86
37
|
/**
|
|
87
38
|
* Update the status of Advanced Security for the organization
|
|
88
39
|
*
|
|
89
|
-
* @param
|
|
40
|
+
* @param orgEnablementSettings - The new status
|
|
90
41
|
*/
|
|
91
|
-
|
|
42
|
+
updateOrgEnablementStatus3(orgEnablementSettings: Management.OrgEnablementSettings): Promise<void>;
|
|
92
43
|
/**
|
|
93
44
|
* Estimate the pushers that would be added to the customer's usage if Advanced Security was enabled for this organization.
|
|
94
45
|
*
|
|
46
|
+
* @param plan - The plan to query.
|
|
95
47
|
*/
|
|
96
|
-
|
|
97
|
-
/**
|
|
98
|
-
* Estimate the committers that would be added to the customer's usage if Advanced Security was enabled for this organization.
|
|
99
|
-
*
|
|
100
|
-
*/
|
|
101
|
-
getEstimatedOrgBillablePushers(): Promise<string[]>;
|
|
102
|
-
/**
|
|
103
|
-
* Estimate the pushers that would be added to the customer's usage if Advanced Security was enabled for this organization.
|
|
104
|
-
*
|
|
105
|
-
*/
|
|
106
|
-
getEstimatedBillablePushersDetailsForOrg2(): Promise<Management.MeterUsageEstimate>;
|
|
107
|
-
/**
|
|
108
|
-
* Estimate the committers that would be added to the customer's usage if Advanced Security was enabled for this organization.
|
|
109
|
-
*
|
|
110
|
-
*/
|
|
111
|
-
getEstimatedOrgBillablePushers2(): Promise<string[]>;
|
|
112
|
-
/**
|
|
113
|
-
* Get the current status of Advanced Security for a project
|
|
114
|
-
*
|
|
115
|
-
* @param project - Project ID or project name
|
|
116
|
-
* @param includeAllProperties - When true, also determine if pushes are blocked if they contain secrets
|
|
117
|
-
*/
|
|
118
|
-
getProjectEnablementStatus(project: string, includeAllProperties?: boolean): Promise<Management.AdvSecEnablementSettings>;
|
|
119
|
-
/**
|
|
120
|
-
* Update the status of Advanced Security for the project
|
|
121
|
-
*
|
|
122
|
-
* @param savedAdvSecEnablementStatus - The new status
|
|
123
|
-
* @param project - Project ID or project name
|
|
124
|
-
*/
|
|
125
|
-
updateProjectEnablementStatus(savedAdvSecEnablementStatus: Management.AdvSecEnablementSettingsUpdate, project: string): Promise<void>;
|
|
48
|
+
getEstimatedBillablePushersDetailsForOrg3(plan: Management.Plan): Promise<Management.MeterUsageEstimate>;
|
|
126
49
|
/**
|
|
127
50
|
* Get the current status of Advanced Security for a project
|
|
128
51
|
*
|
|
129
52
|
* @param project - Project ID or project name
|
|
130
53
|
* @param includeAllProperties - When true, also determine if pushes are blocked if they contain secrets
|
|
131
54
|
*/
|
|
132
|
-
|
|
55
|
+
getProjectEnablementStatus3(project: string, includeAllProperties?: boolean): Promise<Management.ProjectEnablementSettings>;
|
|
133
56
|
/**
|
|
134
57
|
* Update the status of Advanced Security for the project
|
|
135
58
|
*
|
|
136
|
-
* @param
|
|
59
|
+
* @param projectEnablementSettings - The new status
|
|
137
60
|
* @param project - Project ID or project name
|
|
138
61
|
*/
|
|
139
|
-
|
|
62
|
+
updateProjectEnablementStatus3(projectEnablementSettings: Management.ProjectEnablementSettings, project: string): Promise<void>;
|
|
140
63
|
/**
|
|
141
64
|
* Estimate the pushers that would be added to the customer's usage if Advanced Security was enabled for this project.
|
|
142
65
|
*
|
|
143
66
|
* @param project - Project ID or project name
|
|
67
|
+
* @param plan -
|
|
144
68
|
*/
|
|
145
|
-
|
|
146
|
-
/**
|
|
147
|
-
* Estimate the number of committers that would be added to the customer's usage if Advanced Security was enabled for this project.
|
|
148
|
-
*
|
|
149
|
-
* @param project - Project ID or project name
|
|
150
|
-
*/
|
|
151
|
-
getEstimatedProjectBillablePushers(project: string): Promise<string[]>;
|
|
152
|
-
/**
|
|
153
|
-
* Estimate the pushers that would be added to the customer's usage if Advanced Security was enabled for this project.
|
|
154
|
-
*
|
|
155
|
-
* @param project - Project ID or project name
|
|
156
|
-
*/
|
|
157
|
-
getEstimatedBillablePushersDetailsForProject2(project: string): Promise<Management.MeterUsageEstimate>;
|
|
158
|
-
/**
|
|
159
|
-
* Estimate the number of committers that would be added to the customer's usage if Advanced Security was enabled for this project.
|
|
160
|
-
*
|
|
161
|
-
* @param project - Project ID or project name
|
|
162
|
-
*/
|
|
163
|
-
getEstimatedProjectBillablePushers2(project: string): Promise<string[]>;
|
|
69
|
+
getEstimatedBillablePushersDetailsForProject3(project: string, plan?: Management.Plan): Promise<Management.MeterUsageEstimate>;
|
|
164
70
|
/**
|
|
165
|
-
*
|
|
71
|
+
* Determines if Code Security, Secret Protection, and their features are enabled for the repository.
|
|
166
72
|
*
|
|
167
73
|
* @param project - Project ID or project name
|
|
168
74
|
* @param repository - The name or ID of the repository
|
|
169
75
|
* @param includeAllProperties - When true, will also determine if pushes are blocked when secrets are detected
|
|
170
76
|
*/
|
|
171
|
-
|
|
77
|
+
getRepoEnablementStatus3(project: string, repository: string, includeAllProperties?: boolean): Promise<Management.RepoEnablementSettings>;
|
|
172
78
|
/**
|
|
173
|
-
* Update the enablement of
|
|
79
|
+
* Update the enablement status of Code Security and Secret Protection, along with their respective features, for a given repository.
|
|
174
80
|
*
|
|
175
81
|
* @param savedAdvSecEnablementStatus - new status
|
|
176
82
|
* @param project - Project ID or project name
|
|
177
83
|
* @param repository - Name or ID of the repository
|
|
178
84
|
*/
|
|
179
|
-
|
|
180
|
-
/**
|
|
181
|
-
* Estimate the committers that would be added to the customer's usage if Advanced Security was enabled for this repository.
|
|
182
|
-
*
|
|
183
|
-
* @param project - Project ID or project name
|
|
184
|
-
* @param repository - The name or ID of the repository
|
|
185
|
-
*/
|
|
186
|
-
getEstimatedRepoBillableCommitters(project: string, repository: string): Promise<string[]>;
|
|
85
|
+
updateRepoAdvSecEnablementStatus3(savedAdvSecEnablementStatus: Management.RepoEnablementSettings, project: string, repository: string): Promise<void>;
|
|
187
86
|
/**
|
|
188
87
|
* Estimate the pushers that would be added to the customer's usage if Advanced Security was enabled for this repository.
|
|
189
88
|
*
|
|
190
89
|
* @param project - Project ID or project name
|
|
191
|
-
* @param repository -
|
|
192
|
-
*/
|
|
193
|
-
getEstimatedRepoBillablePushersDetails(project: string, repository: string): Promise<Management.BilledCommitter[]>;
|
|
194
|
-
/**
|
|
195
|
-
* Estimate the committers that would be added to the customer's usage if Advanced Security was enabled for this repository.
|
|
196
|
-
*
|
|
197
|
-
* @param project - Project ID or project name
|
|
198
90
|
* @param repository - The name or ID of the repository
|
|
91
|
+
* @param plan - The plan to query.
|
|
199
92
|
*/
|
|
200
|
-
|
|
201
|
-
/**
|
|
202
|
-
* Estimate the pushers that would be added to the customer's usage if Advanced Security was enabled for this repository.
|
|
203
|
-
*
|
|
204
|
-
* @param project - Project ID or project name
|
|
205
|
-
* @param repository -
|
|
206
|
-
*/
|
|
207
|
-
getEstimatedRepoBillableCommittersDetails2(project: string, repository: string): Promise<Management.MeterUsageEstimate>;
|
|
93
|
+
getEstimatedBillableCommittersDetailsForRepo3(project: string, repository: string, plan?: Management.Plan): Promise<Management.MeterUsageEstimate>;
|
|
208
94
|
}
|