oci-securityattribute 2.95.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (203) hide show
  1. package/LICENSE.txt +89 -0
  2. package/NOTICE.txt +1 -0
  3. package/README.md +22 -0
  4. package/THIRD_PARTY_LICENSES.txt +576 -0
  5. package/index.d.ts +22 -0
  6. package/index.js +45 -0
  7. package/index.js.map +1 -0
  8. package/lib/client.d.ts +533 -0
  9. package/lib/client.js +1671 -0
  10. package/lib/client.js.map +1 -0
  11. package/lib/model/base-security-attribute-validator.d.ts +33 -0
  12. package/lib/model/base-security-attribute-validator.js +72 -0
  13. package/lib/model/base-security-attribute-validator.js.map +1 -0
  14. package/lib/model/bulk-delete-security-attributes-details.d.ts +25 -0
  15. package/lib/model/bulk-delete-security-attributes-details.js +29 -0
  16. package/lib/model/bulk-delete-security-attributes-details.js.map +1 -0
  17. package/lib/model/bulk-edit-resource.d.ts +33 -0
  18. package/lib/model/bulk-edit-resource.js +29 -0
  19. package/lib/model/bulk-edit-resource.js.map +1 -0
  20. package/lib/model/bulk-edit-security-attribute-details.d.ts +34 -0
  21. package/lib/model/bulk-edit-security-attribute-details.js +71 -0
  22. package/lib/model/bulk-edit-security-attribute-details.js.map +1 -0
  23. package/lib/model/bulk-edit-security-attribute-operation-details.d.ts +46 -0
  24. package/lib/model/bulk-edit-security-attribute-operation-details.js +36 -0
  25. package/lib/model/bulk-edit-security-attribute-operation-details.js.map +1 -0
  26. package/lib/model/change-security-attribute-namespace-compartment-details.d.ts +26 -0
  27. package/lib/model/change-security-attribute-namespace-compartment-details.js +29 -0
  28. package/lib/model/change-security-attribute-namespace-compartment-details.js.map +1 -0
  29. package/lib/model/create-security-attribute-details.d.ts +34 -0
  30. package/lib/model/create-security-attribute-details.js +57 -0
  31. package/lib/model/create-security-attribute-details.js.map +1 -0
  32. package/lib/model/create-security-attribute-namespace-details.d.ts +57 -0
  33. package/lib/model/create-security-attribute-namespace-details.js +29 -0
  34. package/lib/model/create-security-attribute-namespace-details.js.map +1 -0
  35. package/lib/model/default-security-attribute-validator.d.ts +27 -0
  36. package/lib/model/default-security-attribute-validator.js +54 -0
  37. package/lib/model/default-security-attribute-validator.js.map +1 -0
  38. package/lib/model/enum-security-attribute-validator.d.ts +33 -0
  39. package/lib/model/enum-security-attribute-validator.js +54 -0
  40. package/lib/model/enum-security-attribute-validator.js.map +1 -0
  41. package/lib/model/index.d.ts +60 -0
  42. package/lib/model/index.js +83 -0
  43. package/lib/model/index.js.map +1 -0
  44. package/lib/model/security-attribute-namespace-summary.d.ts +93 -0
  45. package/lib/model/security-attribute-namespace-summary.js +29 -0
  46. package/lib/model/security-attribute-namespace-summary.js.map +1 -0
  47. package/lib/model/security-attribute-namespace.d.ts +109 -0
  48. package/lib/model/security-attribute-namespace.js +41 -0
  49. package/lib/model/security-attribute-namespace.js.map +1 -0
  50. package/lib/model/security-attribute-summary.d.ts +69 -0
  51. package/lib/model/security-attribute-summary.js +29 -0
  52. package/lib/model/security-attribute-summary.js.map +1 -0
  53. package/lib/model/security-attribute-work-request-error-summary.d.ts +36 -0
  54. package/lib/model/security-attribute-work-request-error-summary.js +29 -0
  55. package/lib/model/security-attribute-work-request-error-summary.js.map +1 -0
  56. package/lib/model/security-attribute-work-request-log-summary.d.ts +32 -0
  57. package/lib/model/security-attribute-work-request-log-summary.js +29 -0
  58. package/lib/model/security-attribute-work-request-log-summary.js.map +1 -0
  59. package/lib/model/security-attribute-work-request-summary.d.ts +67 -0
  60. package/lib/model/security-attribute-work-request-summary.js +61 -0
  61. package/lib/model/security-attribute-work-request-summary.js.map +1 -0
  62. package/lib/model/security-attribute-work-request.d.ts +68 -0
  63. package/lib/model/security-attribute-work-request.js +61 -0
  64. package/lib/model/security-attribute-work-request.js.map +1 -0
  65. package/lib/model/security-attribute.d.ts +88 -0
  66. package/lib/model/security-attribute.js +69 -0
  67. package/lib/model/security-attribute.js.map +1 -0
  68. package/lib/model/sort-order.d.ts +30 -0
  69. package/lib/model/sort-order.js +41 -0
  70. package/lib/model/sort-order.js.map +1 -0
  71. package/lib/model/update-security-attribute-details.d.ts +34 -0
  72. package/lib/model/update-security-attribute-details.js +57 -0
  73. package/lib/model/update-security-attribute-details.js.map +1 -0
  74. package/lib/model/update-security-attribute-namespace-details.d.ts +54 -0
  75. package/lib/model/update-security-attribute-namespace-details.js +29 -0
  76. package/lib/model/update-security-attribute-namespace-details.js.map +1 -0
  77. package/lib/model/work-request-operation-type.d.ts +30 -0
  78. package/lib/model/work-request-operation-type.js +41 -0
  79. package/lib/model/work-request-operation-type.js.map +1 -0
  80. package/lib/model/work-request-resource.d.ts +51 -0
  81. package/lib/model/work-request-resource.js +43 -0
  82. package/lib/model/work-request-resource.js.map +1 -0
  83. package/lib/model/work-request-status.d.ts +33 -0
  84. package/lib/model/work-request-status.js +44 -0
  85. package/lib/model/work-request-status.js.map +1 -0
  86. package/lib/request/bulk-delete-security-attributes-request.d.ts +40 -0
  87. package/lib/request/bulk-delete-security-attributes-request.js +15 -0
  88. package/lib/request/bulk-delete-security-attributes-request.js.map +1 -0
  89. package/lib/request/bulk-edit-security-attributes-request.d.ts +40 -0
  90. package/lib/request/bulk-edit-security-attributes-request.js +15 -0
  91. package/lib/request/bulk-edit-security-attributes-request.js.map +1 -0
  92. package/lib/request/cascading-delete-security-attribute-namespace-request.d.ts +48 -0
  93. package/lib/request/cascading-delete-security-attribute-namespace-request.js +15 -0
  94. package/lib/request/cascading-delete-security-attribute-namespace-request.js.map +1 -0
  95. package/lib/request/change-security-attribute-namespace-compartment-request.d.ts +53 -0
  96. package/lib/request/change-security-attribute-namespace-compartment-request.js +15 -0
  97. package/lib/request/change-security-attribute-namespace-compartment-request.js.map +1 -0
  98. package/lib/request/create-security-attribute-namespace-request.d.ts +40 -0
  99. package/lib/request/create-security-attribute-namespace-request.js +15 -0
  100. package/lib/request/create-security-attribute-namespace-request.js.map +1 -0
  101. package/lib/request/create-security-attribute-request.d.ts +45 -0
  102. package/lib/request/create-security-attribute-request.js +15 -0
  103. package/lib/request/create-security-attribute-request.js.map +1 -0
  104. package/lib/request/delete-security-attribute-namespace-request.d.ts +48 -0
  105. package/lib/request/delete-security-attribute-namespace-request.js +15 -0
  106. package/lib/request/delete-security-attribute-namespace-request.js.map +1 -0
  107. package/lib/request/delete-security-attribute-request.d.ts +53 -0
  108. package/lib/request/delete-security-attribute-request.js +15 -0
  109. package/lib/request/delete-security-attribute-request.js.map +1 -0
  110. package/lib/request/get-security-attribute-namespace-request.d.ts +31 -0
  111. package/lib/request/get-security-attribute-namespace-request.js +15 -0
  112. package/lib/request/get-security-attribute-namespace-request.js.map +1 -0
  113. package/lib/request/get-security-attribute-request.d.ts +36 -0
  114. package/lib/request/get-security-attribute-request.js +15 -0
  115. package/lib/request/get-security-attribute-request.js.map +1 -0
  116. package/lib/request/get-security-attribute-work-request-request.d.ts +30 -0
  117. package/lib/request/get-security-attribute-work-request-request.js +15 -0
  118. package/lib/request/get-security-attribute-work-request-request.js.map +1 -0
  119. package/lib/request/index.d.ts +48 -0
  120. package/lib/request/index.js +37 -0
  121. package/lib/request/index.js.map +1 -0
  122. package/lib/request/list-security-attribute-namespaces-request.d.ts +78 -0
  123. package/lib/request/list-security-attribute-namespaces-request.js +24 -0
  124. package/lib/request/list-security-attribute-namespaces-request.js.map +1 -0
  125. package/lib/request/list-security-attribute-work-request-errors-request.d.ts +40 -0
  126. package/lib/request/list-security-attribute-work-request-errors-request.js +15 -0
  127. package/lib/request/list-security-attribute-work-request-errors-request.js.map +1 -0
  128. package/lib/request/list-security-attribute-work-request-logs-request.d.ts +40 -0
  129. package/lib/request/list-security-attribute-work-request-logs-request.js +15 -0
  130. package/lib/request/list-security-attribute-work-request-logs-request.js.map +1 -0
  131. package/lib/request/list-security-attribute-work-requests-request.d.ts +44 -0
  132. package/lib/request/list-security-attribute-work-requests-request.js +15 -0
  133. package/lib/request/list-security-attribute-work-requests-request.js.map +1 -0
  134. package/lib/request/list-security-attributes-request.d.ts +46 -0
  135. package/lib/request/list-security-attributes-request.js +15 -0
  136. package/lib/request/list-security-attributes-request.js.map +1 -0
  137. package/lib/request/update-security-attribute-namespace-request.d.ts +53 -0
  138. package/lib/request/update-security-attribute-namespace-request.js +15 -0
  139. package/lib/request/update-security-attribute-namespace-request.js.map +1 -0
  140. package/lib/request/update-security-attribute-request.d.ts +58 -0
  141. package/lib/request/update-security-attribute-request.js +15 -0
  142. package/lib/request/update-security-attribute-request.js.map +1 -0
  143. package/lib/response/bulk-delete-security-attributes-response.d.ts +25 -0
  144. package/lib/response/bulk-delete-security-attributes-response.js +15 -0
  145. package/lib/response/bulk-delete-security-attributes-response.js.map +1 -0
  146. package/lib/response/bulk-edit-security-attributes-response.d.ts +25 -0
  147. package/lib/response/bulk-edit-security-attributes-response.js +15 -0
  148. package/lib/response/bulk-edit-security-attributes-response.js.map +1 -0
  149. package/lib/response/cascading-delete-security-attribute-namespace-response.d.ts +25 -0
  150. package/lib/response/cascading-delete-security-attribute-namespace-response.js +15 -0
  151. package/lib/response/cascading-delete-security-attribute-namespace-response.js.map +1 -0
  152. package/lib/response/change-security-attribute-namespace-compartment-response.d.ts +20 -0
  153. package/lib/response/change-security-attribute-namespace-compartment-response.js +15 -0
  154. package/lib/response/change-security-attribute-namespace-compartment-response.js.map +1 -0
  155. package/lib/response/create-security-attribute-namespace-response.d.ts +29 -0
  156. package/lib/response/create-security-attribute-namespace-response.js +15 -0
  157. package/lib/response/create-security-attribute-namespace-response.js.map +1 -0
  158. package/lib/response/create-security-attribute-response.d.ts +29 -0
  159. package/lib/response/create-security-attribute-response.js +15 -0
  160. package/lib/response/create-security-attribute-response.js.map +1 -0
  161. package/lib/response/delete-security-attribute-namespace-response.d.ts +20 -0
  162. package/lib/response/delete-security-attribute-namespace-response.js +15 -0
  163. package/lib/response/delete-security-attribute-namespace-response.js.map +1 -0
  164. package/lib/response/delete-security-attribute-response.d.ts +25 -0
  165. package/lib/response/delete-security-attribute-response.js +15 -0
  166. package/lib/response/delete-security-attribute-response.js.map +1 -0
  167. package/lib/response/get-security-attribute-namespace-response.d.ts +29 -0
  168. package/lib/response/get-security-attribute-namespace-response.js +15 -0
  169. package/lib/response/get-security-attribute-namespace-response.js.map +1 -0
  170. package/lib/response/get-security-attribute-response.d.ts +29 -0
  171. package/lib/response/get-security-attribute-response.js +15 -0
  172. package/lib/response/get-security-attribute-response.js.map +1 -0
  173. package/lib/response/get-security-attribute-work-request-response.d.ts +30 -0
  174. package/lib/response/get-security-attribute-work-request-response.js +15 -0
  175. package/lib/response/get-security-attribute-work-request-response.js.map +1 -0
  176. package/lib/response/index.d.ts +48 -0
  177. package/lib/response/index.js +15 -0
  178. package/lib/response/index.js.map +1 -0
  179. package/lib/response/list-security-attribute-namespaces-response.d.ts +32 -0
  180. package/lib/response/list-security-attribute-namespaces-response.js +15 -0
  181. package/lib/response/list-security-attribute-namespaces-response.js.map +1 -0
  182. package/lib/response/list-security-attribute-work-request-errors-response.d.ts +37 -0
  183. package/lib/response/list-security-attribute-work-request-errors-response.js +15 -0
  184. package/lib/response/list-security-attribute-work-request-errors-response.js.map +1 -0
  185. package/lib/response/list-security-attribute-work-request-logs-response.d.ts +37 -0
  186. package/lib/response/list-security-attribute-work-request-logs-response.js +15 -0
  187. package/lib/response/list-security-attribute-work-request-logs-response.js.map +1 -0
  188. package/lib/response/list-security-attribute-work-requests-response.d.ts +32 -0
  189. package/lib/response/list-security-attribute-work-requests-response.js +15 -0
  190. package/lib/response/list-security-attribute-work-requests-response.js.map +1 -0
  191. package/lib/response/list-security-attributes-response.d.ts +32 -0
  192. package/lib/response/list-security-attributes-response.js +15 -0
  193. package/lib/response/list-security-attributes-response.js.map +1 -0
  194. package/lib/response/update-security-attribute-namespace-response.d.ts +29 -0
  195. package/lib/response/update-security-attribute-namespace-response.js +15 -0
  196. package/lib/response/update-security-attribute-namespace-response.js.map +1 -0
  197. package/lib/response/update-security-attribute-response.d.ts +29 -0
  198. package/lib/response/update-security-attribute-response.js +15 -0
  199. package/lib/response/update-security-attribute-response.js.map +1 -0
  200. package/lib/securityattribute-waiter.d.ts +44 -0
  201. package/lib/securityattribute-waiter.js +88 -0
  202. package/lib/securityattribute-waiter.js.map +1 -0
  203. package/package.json +29 -0
package/lib/client.js ADDED
@@ -0,0 +1,1671 @@
1
+ "use strict";
2
+ /**
3
+ * Security Attribute API
4
+ * Use the Security Attributes API to manage security attributes and security attribute namespaces. For more information, see the documentation for [Security Attributes](/iaas/Content/zero-trust-packet-routing/managing-security-attributes.htm) and [Security Attribute Nampespaces](/iaas/Content/zero-trust-packet-routing/managing-security-attribute-namespaces.htm).
5
+ * OpenAPI spec version: 20240815
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OracleSDKGenerator.
9
+ * Do not edit the class manually.
10
+ *
11
+ * Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
12
+ * This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
13
+ */
14
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
15
+ if (k2 === undefined) k2 = k;
16
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
17
+ }) : (function(o, m, k, k2) {
18
+ if (k2 === undefined) k2 = k;
19
+ o[k2] = m[k];
20
+ }));
21
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
22
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
23
+ }) : function(o, v) {
24
+ o["default"] = v;
25
+ });
26
+ var __importStar = (this && this.__importStar) || function (mod) {
27
+ if (mod && mod.__esModule) return mod;
28
+ var result = {};
29
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
30
+ __setModuleDefault(result, mod);
31
+ return result;
32
+ };
33
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
34
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
35
+ return new (P || (P = Promise))(function (resolve, reject) {
36
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
37
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
38
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
39
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
40
+ });
41
+ };
42
+ Object.defineProperty(exports, "__esModule", { value: true });
43
+ exports.SecurityAttributeClient = exports.SecurityAttributeApiKeys = void 0;
44
+ const common = require("oci-common");
45
+ const model = __importStar(require("./model"));
46
+ const oci_common_1 = require("oci-common");
47
+ const securityattribute_waiter_1 = require("./securityattribute-waiter");
48
+ const oci_common_2 = require("oci-common");
49
+ const Breaker = require("opossum");
50
+ // ===============================================
51
+ // This file is autogenerated - Please do not edit
52
+ // ===============================================
53
+ var SecurityAttributeApiKeys;
54
+ (function (SecurityAttributeApiKeys) {
55
+ })(SecurityAttributeApiKeys = exports.SecurityAttributeApiKeys || (exports.SecurityAttributeApiKeys = {}));
56
+ /**
57
+ * This service client uses {@link common.CircuitBreaker.DefaultConfiguration} for all the operations by default if no circuit breaker configuration is defined by the user.
58
+ */
59
+ class SecurityAttributeClient {
60
+ constructor(params, clientConfiguration) {
61
+ this["_realmSpecificEndpointTemplateEnabled"] = undefined;
62
+ this["_endpoint"] = "";
63
+ this["_defaultHeaders"] = {};
64
+ this._circuitBreaker = null;
65
+ this._httpOptions = undefined;
66
+ this._bodyDuplexMode = undefined;
67
+ this.targetService = "SecurityAttribute";
68
+ this._regionId = "";
69
+ this._lastSetRegionOrRegionId = "";
70
+ const requestSigner = params.authenticationDetailsProvider
71
+ ? new common.DefaultRequestSigner(params.authenticationDetailsProvider)
72
+ : null;
73
+ if (clientConfiguration) {
74
+ this._clientConfiguration = clientConfiguration;
75
+ this._circuitBreaker = clientConfiguration.circuitBreaker
76
+ ? clientConfiguration.circuitBreaker.circuit
77
+ : null;
78
+ this._httpOptions = clientConfiguration.httpOptions
79
+ ? clientConfiguration.httpOptions
80
+ : undefined;
81
+ this._bodyDuplexMode = clientConfiguration.bodyDuplexMode
82
+ ? clientConfiguration.bodyDuplexMode
83
+ : undefined;
84
+ }
85
+ if (!oci_common_2.developerToolConfiguration.isServiceEnabled("securityattribute")) {
86
+ let errmsg = "The developerToolConfiguration configuration disabled this service, this behavior is controlled by developerToolConfiguration.ociEnabledServiceSet variable. Please check if your local developer_tool_configuration file has configured the service you're targeting or contact the cloud provider on the availability of this service : ";
87
+ throw errmsg.concat("securityattribute");
88
+ }
89
+ // if circuit breaker is not created, check if circuit breaker system is enabled to use default circuit breaker
90
+ const specCircuitBreakerEnabled = true;
91
+ if (!this._circuitBreaker &&
92
+ common.utils.isCircuitBreakerSystemEnabled(clientConfiguration) &&
93
+ (specCircuitBreakerEnabled || common.CircuitBreaker.DefaultCircuitBreakerOverriden)) {
94
+ this._circuitBreaker = new common.CircuitBreaker().circuit;
95
+ }
96
+ this._httpClient =
97
+ params.httpClient ||
98
+ new common.FetchHttpClient(requestSigner, this._circuitBreaker, this._httpOptions, this._bodyDuplexMode);
99
+ if (params.authenticationDetailsProvider &&
100
+ common.isRegionProvider(params.authenticationDetailsProvider)) {
101
+ const provider = params.authenticationDetailsProvider;
102
+ if (provider.getRegion()) {
103
+ this.region = provider.getRegion();
104
+ }
105
+ }
106
+ }
107
+ /**
108
+ * Get the endpoint that is being used to call (ex, https://www.example.com).
109
+ */
110
+ get endpoint() {
111
+ return this._endpoint;
112
+ }
113
+ /**
114
+ * Sets the endpoint to call (ex, https://www.example.com).
115
+ * @param endpoint The endpoint of the service.
116
+ */
117
+ set endpoint(endpoint) {
118
+ this._endpoint = endpoint;
119
+ this._endpoint = this._endpoint + "/20240815";
120
+ if (this.logger)
121
+ this.logger.info(`SecurityAttributeClient endpoint set to ${this._endpoint}`);
122
+ }
123
+ get logger() {
124
+ return common.LOG.logger;
125
+ }
126
+ /**
127
+ * Determines whether realm specific endpoint should be used or not.
128
+ * Set realmSpecificEndpointTemplateEnabled to "true" if the user wants to enable use of realm specific endpoint template, otherwise set it to "false"
129
+ * @param realmSpecificEndpointTemplateEnabled flag to enable the use of realm specific endpoint template
130
+ */
131
+ set useRealmSpecificEndpointTemplate(realmSpecificEndpointTemplateEnabled) {
132
+ this._realmSpecificEndpointTemplateEnabled = realmSpecificEndpointTemplateEnabled;
133
+ if (this.logger)
134
+ this.logger.info(`realmSpecificEndpointTemplateEnabled set to ${this._realmSpecificEndpointTemplateEnabled}`);
135
+ if (this._lastSetRegionOrRegionId === common.Region.REGION_STRING) {
136
+ this.endpoint = common.EndpointBuilder.createEndpointFromRegion(SecurityAttributeClient.serviceEndpointTemplate, this._region, SecurityAttributeClient.endpointServiceName);
137
+ }
138
+ else if (this._lastSetRegionOrRegionId === common.Region.REGION_ID_STRING) {
139
+ this.endpoint = common.EndpointBuilder.createEndpointFromRegionId(SecurityAttributeClient.serviceEndpointTemplate, this._regionId, SecurityAttributeClient.endpointServiceName);
140
+ }
141
+ }
142
+ /**
143
+ * Sets the region to call (ex, Region.US_PHOENIX_1).
144
+ * Note, this will call {@link #endpoint(String) endpoint} after resolving the endpoint.
145
+ * @param region The region of the service.
146
+ */
147
+ set region(region) {
148
+ this._region = region;
149
+ this.endpoint = common.EndpointBuilder.createEndpointFromRegion(SecurityAttributeClient.serviceEndpointTemplate, region, SecurityAttributeClient.endpointServiceName);
150
+ this._lastSetRegionOrRegionId = common.Region.REGION_STRING;
151
+ }
152
+ /**
153
+ * Sets the regionId to call (ex, 'us-phoenix-1').
154
+ *
155
+ * Note, this will first try to map the region ID to a known Region and call {@link #region(Region) region}.
156
+ * If no known Region could be determined, it will create an endpoint assuming its in default Realm OC1
157
+ * and then call {@link #endpoint(String) endpoint}.
158
+ * @param regionId The public region ID.
159
+ */
160
+ set regionId(regionId) {
161
+ this._regionId = regionId;
162
+ this.endpoint = common.EndpointBuilder.createEndpointFromRegionId(SecurityAttributeClient.serviceEndpointTemplate, regionId, SecurityAttributeClient.endpointServiceName);
163
+ this._lastSetRegionOrRegionId = common.Region.REGION_ID_STRING;
164
+ }
165
+ /**
166
+ * Creates a new SecurityAttributeWaiter for resources for this service.
167
+ *
168
+ * @param config The waiter configuration for termination and delay strategy
169
+ * @return The service waiters.
170
+ */
171
+ createWaiters(config) {
172
+ this._waiters = new securityattribute_waiter_1.SecurityAttributeWaiter(this, config);
173
+ return this._waiters;
174
+ }
175
+ /**
176
+ * Gets the waiters available for resources for this service.
177
+ *
178
+ * @return The service waiters.
179
+ */
180
+ getWaiters() {
181
+ if (this._waiters) {
182
+ return this._waiters;
183
+ }
184
+ throw Error("Waiters do not exist. Please create waiters.");
185
+ }
186
+ /**
187
+ * Shutdown the circuit breaker used by the client when it is no longer needed
188
+ */
189
+ shutdownCircuitBreaker() {
190
+ if (this._circuitBreaker) {
191
+ this._circuitBreaker.shutdown();
192
+ }
193
+ }
194
+ /**
195
+ * Close the client once it is no longer needed
196
+ */
197
+ close() {
198
+ this.shutdownCircuitBreaker();
199
+ }
200
+ /**
201
+ * Deletes the specified security attribute definitions. This operation triggers a process that removes the
202
+ * security attributes from all resources in your tenancy. The security attributes must be within the same security attribute namespace.
203
+ *
204
+ * The following actions happen immediately:
205
+ *
206
+ * After you start this operation, the state of the tag changes to DELETING, and security attribute removal
207
+ * from resources begins. This process can take up to 48 hours depending on the number of resources that
208
+ * are tagged and the regions in which those resources reside.
209
+ *
210
+ * When all security attributes have been removed, the state changes to DELETED. You cannot restore a deleted security attribute. After the security attribute state
211
+ * changes to DELETED, you can use the same security attribute name again.
212
+ *
213
+ * After you start this operation, you cannot start either the {@link #deleteSecurityAttribute(DeleteSecurityAttributeRequest) deleteSecurityAttribute} or the {@link #cascadeDeleteSecurityAttributeNamespace(CascadeDeleteSecurityAttributeNamespaceRequest) cascadeDeleteSecurityAttributeNamespace} operation until this process completes.
214
+ *
215
+ * In order to delete security attribute, you must first retire the security attribute. Use {@link #updateSecurityAttribute(UpdateSecurityAttributeRequest) updateSecurityAttribute}
216
+ * to retire a security attribute.
217
+ *
218
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
219
+ * @param BulkDeleteSecurityAttributesRequest
220
+ * @return BulkDeleteSecurityAttributesResponse
221
+ * @throws OciError when an error occurs
222
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/BulkDeleteSecurityAttributes.ts.html |here} to see how to use BulkDeleteSecurityAttributes API.
223
+ */
224
+ bulkDeleteSecurityAttributes(bulkDeleteSecurityAttributesRequest) {
225
+ return __awaiter(this, void 0, void 0, function* () {
226
+ if (this.logger)
227
+ this.logger.debug("Calling operation SecurityAttributeClient#bulkDeleteSecurityAttributes.");
228
+ const operationName = "bulkDeleteSecurityAttributes";
229
+ const apiReferenceLink = "";
230
+ const pathParams = {};
231
+ const queryParams = {};
232
+ let headerParams = {
233
+ "Content-Type": common.Constants.APPLICATION_JSON,
234
+ "opc-request-id": bulkDeleteSecurityAttributesRequest.opcRequestId,
235
+ "opc-retry-token": bulkDeleteSecurityAttributesRequest.opcRetryToken
236
+ };
237
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
238
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, bulkDeleteSecurityAttributesRequest.retryConfiguration, specRetryConfiguration);
239
+ if (this.logger)
240
+ retrier.logger = this.logger;
241
+ const request = yield oci_common_2.composeRequest({
242
+ baseEndpoint: this._endpoint,
243
+ defaultHeaders: this._defaultHeaders,
244
+ path: "/securityAttributes/actions/bulkDelete",
245
+ method: "POST",
246
+ bodyContent: common.ObjectSerializer.serialize(bulkDeleteSecurityAttributesRequest.bulkDeleteSecurityAttributesDetails, "BulkDeleteSecurityAttributesDetails", model.BulkDeleteSecurityAttributesDetails.getJsonObj),
247
+ pathParams: pathParams,
248
+ headerParams: headerParams,
249
+ queryParams: queryParams
250
+ });
251
+ try {
252
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
253
+ const sdkResponse = oci_common_2.composeResponse({
254
+ responseObject: {},
255
+ responseHeaders: [
256
+ {
257
+ value: response.headers.get("opc-request-id"),
258
+ key: "opcRequestId",
259
+ dataType: "string"
260
+ },
261
+ {
262
+ value: response.headers.get("opc-work-request-id"),
263
+ key: "opcWorkRequestId",
264
+ dataType: "string"
265
+ }
266
+ ]
267
+ });
268
+ return sdkResponse;
269
+ }
270
+ catch (err) {
271
+ throw err;
272
+ }
273
+ });
274
+ }
275
+ /**
276
+ * Edits the specified list of security attributes for the selected resources.
277
+ * This operation triggers a process that edits the attributes on all selected resources. The possible actions are:
278
+ * <p>
279
+ * Add a security attribute when it does not already exist on the resource.
280
+ * * Update the value for a security attribute when it is present on the resource.
281
+ * * Add a security attribute when it does not already exist on the resource or update the value when it is present on the resource.
282
+ * * Remove a security attribute from a resource. The security attribute is removed from the resource regardless of the value.
283
+ * <p>
284
+ The edits can include a combination of operations and attributes.
285
+ * However, multiple operations cannot apply to the same attribute in the same request.
286
+ *
287
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
288
+ * @param BulkEditSecurityAttributesRequest
289
+ * @return BulkEditSecurityAttributesResponse
290
+ * @throws OciError when an error occurs
291
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/BulkEditSecurityAttributes.ts.html |here} to see how to use BulkEditSecurityAttributes API.
292
+ */
293
+ bulkEditSecurityAttributes(bulkEditSecurityAttributesRequest) {
294
+ return __awaiter(this, void 0, void 0, function* () {
295
+ if (this.logger)
296
+ this.logger.debug("Calling operation SecurityAttributeClient#bulkEditSecurityAttributes.");
297
+ const operationName = "bulkEditSecurityAttributes";
298
+ const apiReferenceLink = "";
299
+ const pathParams = {};
300
+ const queryParams = {};
301
+ let headerParams = {
302
+ "Content-Type": common.Constants.APPLICATION_JSON,
303
+ "opc-request-id": bulkEditSecurityAttributesRequest.opcRequestId,
304
+ "opc-retry-token": bulkEditSecurityAttributesRequest.opcRetryToken
305
+ };
306
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
307
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, bulkEditSecurityAttributesRequest.retryConfiguration, specRetryConfiguration);
308
+ if (this.logger)
309
+ retrier.logger = this.logger;
310
+ const request = yield oci_common_2.composeRequest({
311
+ baseEndpoint: this._endpoint,
312
+ defaultHeaders: this._defaultHeaders,
313
+ path: "/securityAttributes/actions/bulkEdit",
314
+ method: "POST",
315
+ bodyContent: common.ObjectSerializer.serialize(bulkEditSecurityAttributesRequest.bulkEditSecurityAttributeDetails, "BulkEditSecurityAttributeDetails", model.BulkEditSecurityAttributeDetails.getJsonObj),
316
+ pathParams: pathParams,
317
+ headerParams: headerParams,
318
+ queryParams: queryParams
319
+ });
320
+ try {
321
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
322
+ const sdkResponse = oci_common_2.composeResponse({
323
+ responseObject: {},
324
+ responseHeaders: [
325
+ {
326
+ value: response.headers.get("opc-request-id"),
327
+ key: "opcRequestId",
328
+ dataType: "string"
329
+ },
330
+ {
331
+ value: response.headers.get("opc-work-request-id"),
332
+ key: "opcWorkRequestId",
333
+ dataType: "string"
334
+ }
335
+ ]
336
+ });
337
+ return sdkResponse;
338
+ }
339
+ catch (err) {
340
+ throw err;
341
+ }
342
+ });
343
+ }
344
+ /**
345
+ * Deletes the specified security attribute namespace. This operation triggers a process that removes all of the security attributes
346
+ * defined in the specified security attribute namespace from all resources in your tenancy and then deletes the security attribute namespace.
347
+ * <p>
348
+ After you start the delete operation:
349
+ * <p>
350
+ * New security attribute key definitions cannot be created under the namespace.
351
+ * * The state of the security attribute namespace changes to DELETING.
352
+ * * Security attribute removal from the resources begins.
353
+ * <p>
354
+ This process can take up to 48 hours depending on the number of security attributes in the namespace, the number of resources
355
+ * that are tagged, and the locations of the regions in which those resources reside.
356
+ * <p>
357
+ After all security attributes are removed, the state changes to DELETED. You cannot restore a deleted security attribute namespace. After the deleted security attribute namespace
358
+ * changes its state to DELETED, you can use the name of the deleted security attribute namespace again.
359
+ * <p>
360
+ After you start this operation, you cannot start either the {@link #deleteSecurityAttribute(DeleteSecurityAttributeRequest) deleteSecurityAttribute} or the {@link #bulkDeleteSecurityAttributes(BulkDeleteSecurityAttributesRequest) bulkDeleteSecurityAttributes} operation until this process completes.
361
+ * <p>
362
+ To delete a security attribute namespace, you must first retire it. Use {@link #updateSecurityAttributeNamespace(UpdateSecurityAttributeNamespaceRequest) updateSecurityAttributeNamespace}
363
+ * to retire a security attribute namespace.
364
+ *
365
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
366
+ * @param CascadingDeleteSecurityAttributeNamespaceRequest
367
+ * @return CascadingDeleteSecurityAttributeNamespaceResponse
368
+ * @throws OciError when an error occurs
369
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/CascadingDeleteSecurityAttributeNamespace.ts.html |here} to see how to use CascadingDeleteSecurityAttributeNamespace API.
370
+ */
371
+ cascadingDeleteSecurityAttributeNamespace(cascadingDeleteSecurityAttributeNamespaceRequest) {
372
+ return __awaiter(this, void 0, void 0, function* () {
373
+ if (this.logger)
374
+ this.logger.debug("Calling operation SecurityAttributeClient#cascadingDeleteSecurityAttributeNamespace.");
375
+ const operationName = "cascadingDeleteSecurityAttributeNamespace";
376
+ const apiReferenceLink = "";
377
+ const pathParams = {
378
+ "{securityAttributeNamespaceId}": cascadingDeleteSecurityAttributeNamespaceRequest.securityAttributeNamespaceId
379
+ };
380
+ const queryParams = {};
381
+ let headerParams = {
382
+ "Content-Type": common.Constants.APPLICATION_JSON,
383
+ "if-match": cascadingDeleteSecurityAttributeNamespaceRequest.ifMatch,
384
+ "opc-request-id": cascadingDeleteSecurityAttributeNamespaceRequest.opcRequestId,
385
+ "opc-retry-token": cascadingDeleteSecurityAttributeNamespaceRequest.opcRetryToken
386
+ };
387
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
388
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, cascadingDeleteSecurityAttributeNamespaceRequest.retryConfiguration, specRetryConfiguration);
389
+ if (this.logger)
390
+ retrier.logger = this.logger;
391
+ const request = yield oci_common_2.composeRequest({
392
+ baseEndpoint: this._endpoint,
393
+ defaultHeaders: this._defaultHeaders,
394
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}/actions/cascadeDelete",
395
+ method: "POST",
396
+ pathParams: pathParams,
397
+ headerParams: headerParams,
398
+ queryParams: queryParams
399
+ });
400
+ try {
401
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
402
+ const sdkResponse = oci_common_2.composeResponse({
403
+ responseObject: {},
404
+ responseHeaders: [
405
+ {
406
+ value: response.headers.get("opc-request-id"),
407
+ key: "opcRequestId",
408
+ dataType: "string"
409
+ },
410
+ {
411
+ value: response.headers.get("opc-work-request-id"),
412
+ key: "opcWorkRequestId",
413
+ dataType: "string"
414
+ }
415
+ ]
416
+ });
417
+ return sdkResponse;
418
+ }
419
+ catch (err) {
420
+ throw err;
421
+ }
422
+ });
423
+ }
424
+ /**
425
+ * Moves the specified security attribute namespace to the specified compartment within the same tenancy.
426
+ * <p>
427
+ To move the security attribute namespace, you must have the manage security-attributes permission on both compartments.
428
+ * For more information about IAM policies, see [Details for IAM](https://docs.cloud.oracle.com/Content/Identity/policyreference/iampolicyreference.htm).
429
+ * <p>
430
+ Moving a security attribute namespace moves all the security attributes contained in the security attribute namespace.
431
+ *
432
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
433
+ * @param ChangeSecurityAttributeNamespaceCompartmentRequest
434
+ * @return ChangeSecurityAttributeNamespaceCompartmentResponse
435
+ * @throws OciError when an error occurs
436
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/ChangeSecurityAttributeNamespaceCompartment.ts.html |here} to see how to use ChangeSecurityAttributeNamespaceCompartment API.
437
+ */
438
+ changeSecurityAttributeNamespaceCompartment(changeSecurityAttributeNamespaceCompartmentRequest) {
439
+ return __awaiter(this, void 0, void 0, function* () {
440
+ if (this.logger)
441
+ this.logger.debug("Calling operation SecurityAttributeClient#changeSecurityAttributeNamespaceCompartment.");
442
+ const operationName = "changeSecurityAttributeNamespaceCompartment";
443
+ const apiReferenceLink = "";
444
+ const pathParams = {
445
+ "{securityAttributeNamespaceId}": changeSecurityAttributeNamespaceCompartmentRequest.securityAttributeNamespaceId
446
+ };
447
+ const queryParams = {};
448
+ let headerParams = {
449
+ "Content-Type": common.Constants.APPLICATION_JSON,
450
+ "opc-retry-token": changeSecurityAttributeNamespaceCompartmentRequest.opcRetryToken,
451
+ "if-match": changeSecurityAttributeNamespaceCompartmentRequest.ifMatch,
452
+ "opc-request-id": changeSecurityAttributeNamespaceCompartmentRequest.opcRequestId
453
+ };
454
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
455
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, changeSecurityAttributeNamespaceCompartmentRequest.retryConfiguration, specRetryConfiguration);
456
+ if (this.logger)
457
+ retrier.logger = this.logger;
458
+ const request = yield oci_common_2.composeRequest({
459
+ baseEndpoint: this._endpoint,
460
+ defaultHeaders: this._defaultHeaders,
461
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}/actions/changeCompartment",
462
+ method: "POST",
463
+ bodyContent: common.ObjectSerializer.serialize(changeSecurityAttributeNamespaceCompartmentRequest.changeSecurityAttributeNamespaceCompartmentDetails, "ChangeSecurityAttributeNamespaceCompartmentDetails", model.ChangeSecurityAttributeNamespaceCompartmentDetails.getJsonObj),
464
+ pathParams: pathParams,
465
+ headerParams: headerParams,
466
+ queryParams: queryParams
467
+ });
468
+ try {
469
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
470
+ const sdkResponse = oci_common_2.composeResponse({
471
+ responseObject: {},
472
+ responseHeaders: [
473
+ {
474
+ value: response.headers.get("opc-request-id"),
475
+ key: "opcRequestId",
476
+ dataType: "string"
477
+ }
478
+ ]
479
+ });
480
+ return sdkResponse;
481
+ }
482
+ catch (err) {
483
+ throw err;
484
+ }
485
+ });
486
+ }
487
+ /**
488
+ * Creates a new security attribute in the specified security attribute namespace.
489
+ * <p>
490
+ The security attribute requires either the OCID or the name of the security attribute namespace that will contain this
491
+ * security attribute.
492
+ * <p>
493
+ You must specify a *name* for the attribute, which must be unique across all attributes in the security attribute namespace
494
+ * and cannot be changed. The only valid characters for security attribute names are:\u00A00-9, A-Z, a-z, -, _ characters.
495
+ * Names are case insensitive. That means, for example, \"mySecurityAttribute\" and \"mysecurityattribute\" are not allowed in the same namespace.
496
+ * If you specify a name that's already in use in the security attribute namespace, a 409 error is returned.
497
+ * <p>
498
+ The security attribute must have a *description*. It does not have to be unique, and you can change it with
499
+ * {@link #updateSecurityAttribute(UpdateSecurityAttributeRequest) updateSecurityAttribute}.
500
+ * <p>
501
+ The security attribute must have a value type, which is specified with a validator. Security attribute can use either a
502
+ * static value or a list of possible values. Static values are entered by a user applying the security attribute
503
+ * to a resource. Lists are created by the user and the user must apply a value from the list. Lists
504
+ * are validated.
505
+ *
506
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
507
+ * @param CreateSecurityAttributeRequest
508
+ * @return CreateSecurityAttributeResponse
509
+ * @throws OciError when an error occurs
510
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/CreateSecurityAttribute.ts.html |here} to see how to use CreateSecurityAttribute API.
511
+ */
512
+ createSecurityAttribute(createSecurityAttributeRequest) {
513
+ return __awaiter(this, void 0, void 0, function* () {
514
+ if (this.logger)
515
+ this.logger.debug("Calling operation SecurityAttributeClient#createSecurityAttribute.");
516
+ const operationName = "createSecurityAttribute";
517
+ const apiReferenceLink = "";
518
+ const pathParams = {
519
+ "{securityAttributeNamespaceId}": createSecurityAttributeRequest.securityAttributeNamespaceId
520
+ };
521
+ const queryParams = {};
522
+ let headerParams = {
523
+ "Content-Type": common.Constants.APPLICATION_JSON,
524
+ "opc-request-id": createSecurityAttributeRequest.opcRequestId,
525
+ "opc-retry-token": createSecurityAttributeRequest.opcRetryToken
526
+ };
527
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
528
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, createSecurityAttributeRequest.retryConfiguration, specRetryConfiguration);
529
+ if (this.logger)
530
+ retrier.logger = this.logger;
531
+ const request = yield oci_common_2.composeRequest({
532
+ baseEndpoint: this._endpoint,
533
+ defaultHeaders: this._defaultHeaders,
534
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes",
535
+ method: "POST",
536
+ bodyContent: common.ObjectSerializer.serialize(createSecurityAttributeRequest.createSecurityAttributeDetails, "CreateSecurityAttributeDetails", model.CreateSecurityAttributeDetails.getJsonObj),
537
+ pathParams: pathParams,
538
+ headerParams: headerParams,
539
+ queryParams: queryParams
540
+ });
541
+ try {
542
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
543
+ const sdkResponse = oci_common_2.composeResponse({
544
+ responseObject: {},
545
+ body: yield response.json(),
546
+ bodyKey: "securityAttribute",
547
+ bodyModel: model.SecurityAttribute,
548
+ type: "model.SecurityAttribute",
549
+ responseHeaders: [
550
+ {
551
+ value: response.headers.get("opc-request-id"),
552
+ key: "opcRequestId",
553
+ dataType: "string"
554
+ },
555
+ {
556
+ value: response.headers.get("etag"),
557
+ key: "etag",
558
+ dataType: "string"
559
+ }
560
+ ]
561
+ });
562
+ return sdkResponse;
563
+ }
564
+ catch (err) {
565
+ throw err;
566
+ }
567
+ });
568
+ }
569
+ /**
570
+ * Creates a new security attribute namespace in the specified compartment.
571
+ * <p>
572
+ You must specify the compartment ID in the request object (remember that the tenancy is simply the root
573
+ * compartment).
574
+ * <p>
575
+ You must also specify a *name* for the namespace, which must be unique across all namespaces in your tenancy
576
+ * and cannot be changed. The only valid characters for security attribute names are: \u00A00-9, A-Z, a-z, -, _ characters.
577
+ * Names are case insensitive. That means, for example, \"myNamespace\" and \"mynamespace\" are not allowed
578
+ * in the same tenancy. Once you created a namespace, you cannot change the name.
579
+ * If you specify a name that's already in use in the tenancy, a 409 error is returned.
580
+ * <p>
581
+ You must also specify a *description* for the namespace.
582
+ * It does not have to be unique, and you can change it with
583
+ * {@link #securityAttributeNamespace(SecurityAttributeNamespaceRequest) securityAttributeNamespace}.
584
+ *
585
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
586
+ * @param CreateSecurityAttributeNamespaceRequest
587
+ * @return CreateSecurityAttributeNamespaceResponse
588
+ * @throws OciError when an error occurs
589
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/CreateSecurityAttributeNamespace.ts.html |here} to see how to use CreateSecurityAttributeNamespace API.
590
+ */
591
+ createSecurityAttributeNamespace(createSecurityAttributeNamespaceRequest) {
592
+ return __awaiter(this, void 0, void 0, function* () {
593
+ if (this.logger)
594
+ this.logger.debug("Calling operation SecurityAttributeClient#createSecurityAttributeNamespace.");
595
+ const operationName = "createSecurityAttributeNamespace";
596
+ const apiReferenceLink = "";
597
+ const pathParams = {};
598
+ const queryParams = {};
599
+ let headerParams = {
600
+ "Content-Type": common.Constants.APPLICATION_JSON,
601
+ "opc-retry-token": createSecurityAttributeNamespaceRequest.opcRetryToken,
602
+ "opc-request-id": createSecurityAttributeNamespaceRequest.opcRequestId
603
+ };
604
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
605
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, createSecurityAttributeNamespaceRequest.retryConfiguration, specRetryConfiguration);
606
+ if (this.logger)
607
+ retrier.logger = this.logger;
608
+ const request = yield oci_common_2.composeRequest({
609
+ baseEndpoint: this._endpoint,
610
+ defaultHeaders: this._defaultHeaders,
611
+ path: "/securityAttributeNamespaces",
612
+ method: "POST",
613
+ bodyContent: common.ObjectSerializer.serialize(createSecurityAttributeNamespaceRequest.createSecurityAttributeNamespaceDetails, "CreateSecurityAttributeNamespaceDetails", model.CreateSecurityAttributeNamespaceDetails.getJsonObj),
614
+ pathParams: pathParams,
615
+ headerParams: headerParams,
616
+ queryParams: queryParams
617
+ });
618
+ try {
619
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
620
+ const sdkResponse = oci_common_2.composeResponse({
621
+ responseObject: {},
622
+ body: yield response.json(),
623
+ bodyKey: "securityAttributeNamespace",
624
+ bodyModel: model.SecurityAttributeNamespace,
625
+ type: "model.SecurityAttributeNamespace",
626
+ responseHeaders: [
627
+ {
628
+ value: response.headers.get("opc-request-id"),
629
+ key: "opcRequestId",
630
+ dataType: "string"
631
+ },
632
+ {
633
+ value: response.headers.get("etag"),
634
+ key: "etag",
635
+ dataType: "string"
636
+ }
637
+ ]
638
+ });
639
+ return sdkResponse;
640
+ }
641
+ catch (err) {
642
+ throw err;
643
+ }
644
+ });
645
+ }
646
+ /**
647
+ * Deletes the specified security attribute. This operation triggers a process that removes the
648
+ * security attribute from all resources in your tenancy.
649
+ * <p>
650
+ When you start the delete operation, the state of the security attribute changes to DELETING and security attribute removal
651
+ * from resources begins. This can take up to 48 hours depending on the number of resources that
652
+ * were tagged as well as the regions in which those resources reside.
653
+ * <p>
654
+ When all attributes have been removed, the state changes to DELETED. You cannot restore a deleted attribute. Once the deleted attribute
655
+ * changes its state to DELETED, you can use the same security attribute name again.
656
+ * <p>
657
+ After you start this operation, you cannot start either the {@link #bulkDeleteSecurityAttributes(BulkDeleteSecurityAttributesRequest) bulkDeleteSecurityAttributes} or the {@link #cascadeDeleteTagNamespace(CascadeDeleteTagNamespaceRequest) cascadeDeleteTagNamespace} operation until this process completes.
658
+ * <p>
659
+ To delete a security attribute, you must first retire it. Use {@link #updateSecurityAttribute(UpdateSecurityAttributeRequest) updateSecurityAttribute}
660
+ * to retire a security attribute.
661
+ *
662
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
663
+ * @param DeleteSecurityAttributeRequest
664
+ * @return DeleteSecurityAttributeResponse
665
+ * @throws OciError when an error occurs
666
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/DeleteSecurityAttribute.ts.html |here} to see how to use DeleteSecurityAttribute API.
667
+ */
668
+ deleteSecurityAttribute(deleteSecurityAttributeRequest) {
669
+ return __awaiter(this, void 0, void 0, function* () {
670
+ if (this.logger)
671
+ this.logger.debug("Calling operation SecurityAttributeClient#deleteSecurityAttribute.");
672
+ const operationName = "deleteSecurityAttribute";
673
+ const apiReferenceLink = "";
674
+ const pathParams = {
675
+ "{securityAttributeNamespaceId}": deleteSecurityAttributeRequest.securityAttributeNamespaceId,
676
+ "{securityAttributeName}": deleteSecurityAttributeRequest.securityAttributeName
677
+ };
678
+ const queryParams = {};
679
+ let headerParams = {
680
+ "Content-Type": common.Constants.APPLICATION_JSON,
681
+ "if-match": deleteSecurityAttributeRequest.ifMatch,
682
+ "opc-request-id": deleteSecurityAttributeRequest.opcRequestId,
683
+ "opc-retry-token": deleteSecurityAttributeRequest.opcRetryToken
684
+ };
685
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
686
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, deleteSecurityAttributeRequest.retryConfiguration, specRetryConfiguration);
687
+ if (this.logger)
688
+ retrier.logger = this.logger;
689
+ const request = yield oci_common_2.composeRequest({
690
+ baseEndpoint: this._endpoint,
691
+ defaultHeaders: this._defaultHeaders,
692
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes/{securityAttributeName}",
693
+ method: "DELETE",
694
+ pathParams: pathParams,
695
+ headerParams: headerParams,
696
+ queryParams: queryParams
697
+ });
698
+ try {
699
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
700
+ const sdkResponse = oci_common_2.composeResponse({
701
+ responseObject: {},
702
+ responseHeaders: [
703
+ {
704
+ value: response.headers.get("opc-request-id"),
705
+ key: "opcRequestId",
706
+ dataType: "string"
707
+ },
708
+ {
709
+ value: response.headers.get("opc-work-request-id"),
710
+ key: "opcWorkRequestId",
711
+ dataType: "string"
712
+ }
713
+ ]
714
+ });
715
+ return sdkResponse;
716
+ }
717
+ catch (err) {
718
+ throw err;
719
+ }
720
+ });
721
+ }
722
+ /**
723
+ * Deletes the specified security attribute namespace. Only an empty security attribute namespace can be deleted with this operation. To use this operation
724
+ * to delete a security attribute namespace that contains security attributes, first delete all of its security attributes.
725
+ * Use {@link #deleteSecurityAttribute(DeleteSecurityAttributeRequest) deleteSecurityAttribute} to delete a security attribute.
726
+ *
727
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
728
+ * @param DeleteSecurityAttributeNamespaceRequest
729
+ * @return DeleteSecurityAttributeNamespaceResponse
730
+ * @throws OciError when an error occurs
731
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/DeleteSecurityAttributeNamespace.ts.html |here} to see how to use DeleteSecurityAttributeNamespace API.
732
+ */
733
+ deleteSecurityAttributeNamespace(deleteSecurityAttributeNamespaceRequest) {
734
+ return __awaiter(this, void 0, void 0, function* () {
735
+ if (this.logger)
736
+ this.logger.debug("Calling operation SecurityAttributeClient#deleteSecurityAttributeNamespace.");
737
+ const operationName = "deleteSecurityAttributeNamespace";
738
+ const apiReferenceLink = "";
739
+ const pathParams = {
740
+ "{securityAttributeNamespaceId}": deleteSecurityAttributeNamespaceRequest.securityAttributeNamespaceId
741
+ };
742
+ const queryParams = {};
743
+ let headerParams = {
744
+ "Content-Type": common.Constants.APPLICATION_JSON,
745
+ "if-match": deleteSecurityAttributeNamespaceRequest.ifMatch,
746
+ "opc-request-id": deleteSecurityAttributeNamespaceRequest.opcRequestId,
747
+ "opc-retry-token": deleteSecurityAttributeNamespaceRequest.opcRetryToken
748
+ };
749
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
750
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, deleteSecurityAttributeNamespaceRequest.retryConfiguration, specRetryConfiguration);
751
+ if (this.logger)
752
+ retrier.logger = this.logger;
753
+ const request = yield oci_common_2.composeRequest({
754
+ baseEndpoint: this._endpoint,
755
+ defaultHeaders: this._defaultHeaders,
756
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}",
757
+ method: "DELETE",
758
+ pathParams: pathParams,
759
+ headerParams: headerParams,
760
+ queryParams: queryParams
761
+ });
762
+ try {
763
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
764
+ const sdkResponse = oci_common_2.composeResponse({
765
+ responseObject: {},
766
+ responseHeaders: [
767
+ {
768
+ value: response.headers.get("opc-request-id"),
769
+ key: "opcRequestId",
770
+ dataType: "string"
771
+ }
772
+ ]
773
+ });
774
+ return sdkResponse;
775
+ }
776
+ catch (err) {
777
+ throw err;
778
+ }
779
+ });
780
+ }
781
+ /**
782
+ * Gets the specified security attribute's information.
783
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
784
+ * @param GetSecurityAttributeRequest
785
+ * @return GetSecurityAttributeResponse
786
+ * @throws OciError when an error occurs
787
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/GetSecurityAttribute.ts.html |here} to see how to use GetSecurityAttribute API.
788
+ */
789
+ getSecurityAttribute(getSecurityAttributeRequest) {
790
+ return __awaiter(this, void 0, void 0, function* () {
791
+ if (this.logger)
792
+ this.logger.debug("Calling operation SecurityAttributeClient#getSecurityAttribute.");
793
+ const operationName = "getSecurityAttribute";
794
+ const apiReferenceLink = "";
795
+ const pathParams = {
796
+ "{securityAttributeNamespaceId}": getSecurityAttributeRequest.securityAttributeNamespaceId,
797
+ "{securityAttributeName}": getSecurityAttributeRequest.securityAttributeName
798
+ };
799
+ const queryParams = {};
800
+ let headerParams = {
801
+ "Content-Type": common.Constants.APPLICATION_JSON,
802
+ "opc-request-id": getSecurityAttributeRequest.opcRequestId
803
+ };
804
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
805
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, getSecurityAttributeRequest.retryConfiguration, specRetryConfiguration);
806
+ if (this.logger)
807
+ retrier.logger = this.logger;
808
+ const request = yield oci_common_2.composeRequest({
809
+ baseEndpoint: this._endpoint,
810
+ defaultHeaders: this._defaultHeaders,
811
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes/{securityAttributeName}",
812
+ method: "GET",
813
+ pathParams: pathParams,
814
+ headerParams: headerParams,
815
+ queryParams: queryParams
816
+ });
817
+ try {
818
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
819
+ const sdkResponse = oci_common_2.composeResponse({
820
+ responseObject: {},
821
+ body: yield response.json(),
822
+ bodyKey: "securityAttribute",
823
+ bodyModel: model.SecurityAttribute,
824
+ type: "model.SecurityAttribute",
825
+ responseHeaders: [
826
+ {
827
+ value: response.headers.get("opc-request-id"),
828
+ key: "opcRequestId",
829
+ dataType: "string"
830
+ },
831
+ {
832
+ value: response.headers.get("etag"),
833
+ key: "etag",
834
+ dataType: "string"
835
+ }
836
+ ]
837
+ });
838
+ return sdkResponse;
839
+ }
840
+ catch (err) {
841
+ throw err;
842
+ }
843
+ });
844
+ }
845
+ /**
846
+ * Gets the specified security attribute namespace's information.
847
+ *
848
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
849
+ * @param GetSecurityAttributeNamespaceRequest
850
+ * @return GetSecurityAttributeNamespaceResponse
851
+ * @throws OciError when an error occurs
852
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/GetSecurityAttributeNamespace.ts.html |here} to see how to use GetSecurityAttributeNamespace API.
853
+ */
854
+ getSecurityAttributeNamespace(getSecurityAttributeNamespaceRequest) {
855
+ return __awaiter(this, void 0, void 0, function* () {
856
+ if (this.logger)
857
+ this.logger.debug("Calling operation SecurityAttributeClient#getSecurityAttributeNamespace.");
858
+ const operationName = "getSecurityAttributeNamespace";
859
+ const apiReferenceLink = "";
860
+ const pathParams = {
861
+ "{securityAttributeNamespaceId}": getSecurityAttributeNamespaceRequest.securityAttributeNamespaceId
862
+ };
863
+ const queryParams = {};
864
+ let headerParams = {
865
+ "Content-Type": common.Constants.APPLICATION_JSON,
866
+ "opc-request-id": getSecurityAttributeNamespaceRequest.opcRequestId
867
+ };
868
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
869
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, getSecurityAttributeNamespaceRequest.retryConfiguration, specRetryConfiguration);
870
+ if (this.logger)
871
+ retrier.logger = this.logger;
872
+ const request = yield oci_common_2.composeRequest({
873
+ baseEndpoint: this._endpoint,
874
+ defaultHeaders: this._defaultHeaders,
875
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}",
876
+ method: "GET",
877
+ pathParams: pathParams,
878
+ headerParams: headerParams,
879
+ queryParams: queryParams
880
+ });
881
+ try {
882
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
883
+ const sdkResponse = oci_common_2.composeResponse({
884
+ responseObject: {},
885
+ body: yield response.json(),
886
+ bodyKey: "securityAttributeNamespace",
887
+ bodyModel: model.SecurityAttributeNamespace,
888
+ type: "model.SecurityAttributeNamespace",
889
+ responseHeaders: [
890
+ {
891
+ value: response.headers.get("opc-request-id"),
892
+ key: "opcRequestId",
893
+ dataType: "string"
894
+ },
895
+ {
896
+ value: response.headers.get("etag"),
897
+ key: "etag",
898
+ dataType: "string"
899
+ }
900
+ ]
901
+ });
902
+ return sdkResponse;
903
+ }
904
+ catch (err) {
905
+ throw err;
906
+ }
907
+ });
908
+ }
909
+ /**
910
+ * Gets details on a specified work request. The workRequestID is returned in the opc-work-request-id header
911
+ * for any asynchronous operation in security attributes service.
912
+ *
913
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
914
+ * @param GetSecurityAttributeWorkRequestRequest
915
+ * @return GetSecurityAttributeWorkRequestResponse
916
+ * @throws OciError when an error occurs
917
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/GetSecurityAttributeWorkRequest.ts.html |here} to see how to use GetSecurityAttributeWorkRequest API.
918
+ */
919
+ getSecurityAttributeWorkRequest(getSecurityAttributeWorkRequestRequest) {
920
+ return __awaiter(this, void 0, void 0, function* () {
921
+ if (this.logger)
922
+ this.logger.debug("Calling operation SecurityAttributeClient#getSecurityAttributeWorkRequest.");
923
+ const operationName = "getSecurityAttributeWorkRequest";
924
+ const apiReferenceLink = "";
925
+ const pathParams = {
926
+ "{workRequestId}": getSecurityAttributeWorkRequestRequest.workRequestId
927
+ };
928
+ const queryParams = {};
929
+ let headerParams = {
930
+ "Content-Type": common.Constants.APPLICATION_JSON,
931
+ "opc-request-id": getSecurityAttributeWorkRequestRequest.opcRequestId
932
+ };
933
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
934
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, getSecurityAttributeWorkRequestRequest.retryConfiguration, specRetryConfiguration);
935
+ if (this.logger)
936
+ retrier.logger = this.logger;
937
+ const request = yield oci_common_2.composeRequest({
938
+ baseEndpoint: this._endpoint,
939
+ defaultHeaders: this._defaultHeaders,
940
+ path: "/securityAttributeWorkRequests/{workRequestId}",
941
+ method: "GET",
942
+ pathParams: pathParams,
943
+ headerParams: headerParams,
944
+ queryParams: queryParams
945
+ });
946
+ try {
947
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
948
+ const sdkResponse = oci_common_2.composeResponse({
949
+ responseObject: {},
950
+ body: yield response.json(),
951
+ bodyKey: "securityAttributeWorkRequest",
952
+ bodyModel: model.SecurityAttributeWorkRequest,
953
+ type: "model.SecurityAttributeWorkRequest",
954
+ responseHeaders: [
955
+ {
956
+ value: response.headers.get("opc-request-id"),
957
+ key: "opcRequestId",
958
+ dataType: "string"
959
+ },
960
+ {
961
+ value: response.headers.get("retry-after"),
962
+ key: "retryAfter",
963
+ dataType: "number"
964
+ }
965
+ ]
966
+ });
967
+ return sdkResponse;
968
+ }
969
+ catch (err) {
970
+ throw err;
971
+ }
972
+ });
973
+ }
974
+ /**
975
+ * Lists the security attribute namespaces in the specified compartment.
976
+ *
977
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
978
+ * @param ListSecurityAttributeNamespacesRequest
979
+ * @return ListSecurityAttributeNamespacesResponse
980
+ * @throws OciError when an error occurs
981
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/ListSecurityAttributeNamespaces.ts.html |here} to see how to use ListSecurityAttributeNamespaces API.
982
+ */
983
+ listSecurityAttributeNamespaces(listSecurityAttributeNamespacesRequest) {
984
+ return __awaiter(this, void 0, void 0, function* () {
985
+ if (this.logger)
986
+ this.logger.debug("Calling operation SecurityAttributeClient#listSecurityAttributeNamespaces.");
987
+ const operationName = "listSecurityAttributeNamespaces";
988
+ const apiReferenceLink = "";
989
+ const pathParams = {};
990
+ const queryParams = {
991
+ "compartmentId": listSecurityAttributeNamespacesRequest.compartmentId,
992
+ "page": listSecurityAttributeNamespacesRequest.page,
993
+ "limit": listSecurityAttributeNamespacesRequest.limit,
994
+ "sortOrder": listSecurityAttributeNamespacesRequest.sortOrder,
995
+ "sortBy": listSecurityAttributeNamespacesRequest.sortBy,
996
+ "name": listSecurityAttributeNamespacesRequest.name,
997
+ "compartmentIdInSubtree": listSecurityAttributeNamespacesRequest.compartmentIdInSubtree,
998
+ "lifecycleState": listSecurityAttributeNamespacesRequest.lifecycleState
999
+ };
1000
+ let headerParams = {
1001
+ "Content-Type": common.Constants.APPLICATION_JSON,
1002
+ "opc-request-id": listSecurityAttributeNamespacesRequest.opcRequestId
1003
+ };
1004
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
1005
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listSecurityAttributeNamespacesRequest.retryConfiguration, specRetryConfiguration);
1006
+ if (this.logger)
1007
+ retrier.logger = this.logger;
1008
+ const request = yield oci_common_2.composeRequest({
1009
+ baseEndpoint: this._endpoint,
1010
+ defaultHeaders: this._defaultHeaders,
1011
+ path: "/securityAttributeNamespaces",
1012
+ method: "GET",
1013
+ pathParams: pathParams,
1014
+ headerParams: headerParams,
1015
+ queryParams: queryParams
1016
+ });
1017
+ try {
1018
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
1019
+ const sdkResponse = oci_common_2.composeResponse({
1020
+ responseObject: {},
1021
+ body: yield response.json(),
1022
+ bodyKey: "items",
1023
+ bodyModel: model.SecurityAttributeNamespaceSummary,
1024
+ type: "Array<model.SecurityAttributeNamespaceSummary>",
1025
+ responseHeaders: [
1026
+ {
1027
+ value: response.headers.get("opc-request-id"),
1028
+ key: "opcRequestId",
1029
+ dataType: "string"
1030
+ },
1031
+ {
1032
+ value: response.headers.get("opc-next-page"),
1033
+ key: "opcNextPage",
1034
+ dataType: "string"
1035
+ }
1036
+ ]
1037
+ });
1038
+ return sdkResponse;
1039
+ }
1040
+ catch (err) {
1041
+ throw err;
1042
+ }
1043
+ });
1044
+ }
1045
+ /**
1046
+ * NOTE: This function is deprecated in favor of listSecurityAttributeNamespacesRecordIterator function.
1047
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeNamespaceSummary objects
1048
+ * contained in responses from the listSecurityAttributeNamespaces operation. This iterator will fetch more data from the
1049
+ * server as needed.
1050
+ *
1051
+ * @param request a request which can be sent to the service operation
1052
+ */
1053
+ listAllSecurityAttributeNamespaces(request) {
1054
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributeNamespaces(req));
1055
+ }
1056
+ /**
1057
+ * NOTE: This function is deprecated in favor of listSecurityAttributeNamespacesResponseIterator function.
1058
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributeNamespaces operation. This iterator
1059
+ * will fetch more data from the server as needed.
1060
+ *
1061
+ * @param request a request which can be sent to the service operation
1062
+ */
1063
+ listAllSecurityAttributeNamespacesResponses(request) {
1064
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributeNamespaces(req));
1065
+ }
1066
+ /**
1067
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeNamespaceSummary objects
1068
+ * contained in responses from the listSecurityAttributeNamespaces operation. This iterator will fetch more data from the
1069
+ * server as needed.
1070
+ *
1071
+ * @param request a request which can be sent to the service operation
1072
+ */
1073
+ listSecurityAttributeNamespacesRecordIterator(request) {
1074
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributeNamespaces(req));
1075
+ }
1076
+ /**
1077
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributeNamespaces operation. This iterator
1078
+ * will fetch more data from the server as needed.
1079
+ *
1080
+ * @param request a request which can be sent to the service operation
1081
+ */
1082
+ listSecurityAttributeNamespacesResponseIterator(request) {
1083
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributeNamespaces(req));
1084
+ }
1085
+ /**
1086
+ * Gets the errors for a work request.
1087
+ *
1088
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
1089
+ * @param ListSecurityAttributeWorkRequestErrorsRequest
1090
+ * @return ListSecurityAttributeWorkRequestErrorsResponse
1091
+ * @throws OciError when an error occurs
1092
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/ListSecurityAttributeWorkRequestErrors.ts.html |here} to see how to use ListSecurityAttributeWorkRequestErrors API.
1093
+ */
1094
+ listSecurityAttributeWorkRequestErrors(listSecurityAttributeWorkRequestErrorsRequest) {
1095
+ return __awaiter(this, void 0, void 0, function* () {
1096
+ if (this.logger)
1097
+ this.logger.debug("Calling operation SecurityAttributeClient#listSecurityAttributeWorkRequestErrors.");
1098
+ const operationName = "listSecurityAttributeWorkRequestErrors";
1099
+ const apiReferenceLink = "";
1100
+ const pathParams = {
1101
+ "{workRequestId}": listSecurityAttributeWorkRequestErrorsRequest.workRequestId
1102
+ };
1103
+ const queryParams = {
1104
+ "page": listSecurityAttributeWorkRequestErrorsRequest.page,
1105
+ "limit": listSecurityAttributeWorkRequestErrorsRequest.limit
1106
+ };
1107
+ let headerParams = {
1108
+ "Content-Type": common.Constants.APPLICATION_JSON,
1109
+ "opc-request-id": listSecurityAttributeWorkRequestErrorsRequest.opcRequestId
1110
+ };
1111
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
1112
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listSecurityAttributeWorkRequestErrorsRequest.retryConfiguration, specRetryConfiguration);
1113
+ if (this.logger)
1114
+ retrier.logger = this.logger;
1115
+ const request = yield oci_common_2.composeRequest({
1116
+ baseEndpoint: this._endpoint,
1117
+ defaultHeaders: this._defaultHeaders,
1118
+ path: "/securityAttributeWorkRequests/{workRequestId}/errors",
1119
+ method: "GET",
1120
+ pathParams: pathParams,
1121
+ headerParams: headerParams,
1122
+ queryParams: queryParams
1123
+ });
1124
+ try {
1125
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
1126
+ const sdkResponse = oci_common_2.composeResponse({
1127
+ responseObject: {},
1128
+ body: yield response.json(),
1129
+ bodyKey: "items",
1130
+ bodyModel: model.SecurityAttributeWorkRequestErrorSummary,
1131
+ type: "Array<model.SecurityAttributeWorkRequestErrorSummary>",
1132
+ responseHeaders: [
1133
+ {
1134
+ value: response.headers.get("opc-request-id"),
1135
+ key: "opcRequestId",
1136
+ dataType: "string"
1137
+ },
1138
+ {
1139
+ value: response.headers.get("retry-after"),
1140
+ key: "retryAfter",
1141
+ dataType: "number"
1142
+ },
1143
+ {
1144
+ value: response.headers.get("opc-next-page"),
1145
+ key: "opcNextPage",
1146
+ dataType: "string"
1147
+ }
1148
+ ]
1149
+ });
1150
+ return sdkResponse;
1151
+ }
1152
+ catch (err) {
1153
+ throw err;
1154
+ }
1155
+ });
1156
+ }
1157
+ /**
1158
+ * NOTE: This function is deprecated in favor of listSecurityAttributeWorkRequestErrorsRecordIterator function.
1159
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeWorkRequestErrorSummary objects
1160
+ * contained in responses from the listSecurityAttributeWorkRequestErrors operation. This iterator will fetch more data from the
1161
+ * server as needed.
1162
+ *
1163
+ * @param request a request which can be sent to the service operation
1164
+ */
1165
+ listAllSecurityAttributeWorkRequestErrors(request) {
1166
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributeWorkRequestErrors(req));
1167
+ }
1168
+ /**
1169
+ * NOTE: This function is deprecated in favor of listSecurityAttributeWorkRequestErrorsResponseIterator function.
1170
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributeWorkRequestErrors operation. This iterator
1171
+ * will fetch more data from the server as needed.
1172
+ *
1173
+ * @param request a request which can be sent to the service operation
1174
+ */
1175
+ listAllSecurityAttributeWorkRequestErrorsResponses(request) {
1176
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributeWorkRequestErrors(req));
1177
+ }
1178
+ /**
1179
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeWorkRequestErrorSummary objects
1180
+ * contained in responses from the listSecurityAttributeWorkRequestErrors operation. This iterator will fetch more data from the
1181
+ * server as needed.
1182
+ *
1183
+ * @param request a request which can be sent to the service operation
1184
+ */
1185
+ listSecurityAttributeWorkRequestErrorsRecordIterator(request) {
1186
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributeWorkRequestErrors(req));
1187
+ }
1188
+ /**
1189
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributeWorkRequestErrors operation. This iterator
1190
+ * will fetch more data from the server as needed.
1191
+ *
1192
+ * @param request a request which can be sent to the service operation
1193
+ */
1194
+ listSecurityAttributeWorkRequestErrorsResponseIterator(request) {
1195
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributeWorkRequestErrors(req));
1196
+ }
1197
+ /**
1198
+ * Gets the logs for a work request.
1199
+ *
1200
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
1201
+ * @param ListSecurityAttributeWorkRequestLogsRequest
1202
+ * @return ListSecurityAttributeWorkRequestLogsResponse
1203
+ * @throws OciError when an error occurs
1204
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/ListSecurityAttributeWorkRequestLogs.ts.html |here} to see how to use ListSecurityAttributeWorkRequestLogs API.
1205
+ */
1206
+ listSecurityAttributeWorkRequestLogs(listSecurityAttributeWorkRequestLogsRequest) {
1207
+ return __awaiter(this, void 0, void 0, function* () {
1208
+ if (this.logger)
1209
+ this.logger.debug("Calling operation SecurityAttributeClient#listSecurityAttributeWorkRequestLogs.");
1210
+ const operationName = "listSecurityAttributeWorkRequestLogs";
1211
+ const apiReferenceLink = "";
1212
+ const pathParams = {
1213
+ "{workRequestId}": listSecurityAttributeWorkRequestLogsRequest.workRequestId
1214
+ };
1215
+ const queryParams = {
1216
+ "page": listSecurityAttributeWorkRequestLogsRequest.page,
1217
+ "limit": listSecurityAttributeWorkRequestLogsRequest.limit
1218
+ };
1219
+ let headerParams = {
1220
+ "Content-Type": common.Constants.APPLICATION_JSON,
1221
+ "opc-request-id": listSecurityAttributeWorkRequestLogsRequest.opcRequestId
1222
+ };
1223
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
1224
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listSecurityAttributeWorkRequestLogsRequest.retryConfiguration, specRetryConfiguration);
1225
+ if (this.logger)
1226
+ retrier.logger = this.logger;
1227
+ const request = yield oci_common_2.composeRequest({
1228
+ baseEndpoint: this._endpoint,
1229
+ defaultHeaders: this._defaultHeaders,
1230
+ path: "/securityAttributeWorkRequests/{workRequestId}/logs",
1231
+ method: "GET",
1232
+ pathParams: pathParams,
1233
+ headerParams: headerParams,
1234
+ queryParams: queryParams
1235
+ });
1236
+ try {
1237
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
1238
+ const sdkResponse = oci_common_2.composeResponse({
1239
+ responseObject: {},
1240
+ body: yield response.json(),
1241
+ bodyKey: "items",
1242
+ bodyModel: model.SecurityAttributeWorkRequestLogSummary,
1243
+ type: "Array<model.SecurityAttributeWorkRequestLogSummary>",
1244
+ responseHeaders: [
1245
+ {
1246
+ value: response.headers.get("opc-request-id"),
1247
+ key: "opcRequestId",
1248
+ dataType: "string"
1249
+ },
1250
+ {
1251
+ value: response.headers.get("retry-after"),
1252
+ key: "retryAfter",
1253
+ dataType: "number"
1254
+ },
1255
+ {
1256
+ value: response.headers.get("opc-next-page"),
1257
+ key: "opcNextPage",
1258
+ dataType: "string"
1259
+ }
1260
+ ]
1261
+ });
1262
+ return sdkResponse;
1263
+ }
1264
+ catch (err) {
1265
+ throw err;
1266
+ }
1267
+ });
1268
+ }
1269
+ /**
1270
+ * NOTE: This function is deprecated in favor of listSecurityAttributeWorkRequestLogsRecordIterator function.
1271
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeWorkRequestLogSummary objects
1272
+ * contained in responses from the listSecurityAttributeWorkRequestLogs operation. This iterator will fetch more data from the
1273
+ * server as needed.
1274
+ *
1275
+ * @param request a request which can be sent to the service operation
1276
+ */
1277
+ listAllSecurityAttributeWorkRequestLogs(request) {
1278
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributeWorkRequestLogs(req));
1279
+ }
1280
+ /**
1281
+ * NOTE: This function is deprecated in favor of listSecurityAttributeWorkRequestLogsResponseIterator function.
1282
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributeWorkRequestLogs operation. This iterator
1283
+ * will fetch more data from the server as needed.
1284
+ *
1285
+ * @param request a request which can be sent to the service operation
1286
+ */
1287
+ listAllSecurityAttributeWorkRequestLogsResponses(request) {
1288
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributeWorkRequestLogs(req));
1289
+ }
1290
+ /**
1291
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeWorkRequestLogSummary objects
1292
+ * contained in responses from the listSecurityAttributeWorkRequestLogs operation. This iterator will fetch more data from the
1293
+ * server as needed.
1294
+ *
1295
+ * @param request a request which can be sent to the service operation
1296
+ */
1297
+ listSecurityAttributeWorkRequestLogsRecordIterator(request) {
1298
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributeWorkRequestLogs(req));
1299
+ }
1300
+ /**
1301
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributeWorkRequestLogs operation. This iterator
1302
+ * will fetch more data from the server as needed.
1303
+ *
1304
+ * @param request a request which can be sent to the service operation
1305
+ */
1306
+ listSecurityAttributeWorkRequestLogsResponseIterator(request) {
1307
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributeWorkRequestLogs(req));
1308
+ }
1309
+ /**
1310
+ * Lists the security attribute work requests in compartment.
1311
+ *
1312
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
1313
+ * @param ListSecurityAttributeWorkRequestsRequest
1314
+ * @return ListSecurityAttributeWorkRequestsResponse
1315
+ * @throws OciError when an error occurs
1316
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/ListSecurityAttributeWorkRequests.ts.html |here} to see how to use ListSecurityAttributeWorkRequests API.
1317
+ */
1318
+ listSecurityAttributeWorkRequests(listSecurityAttributeWorkRequestsRequest) {
1319
+ return __awaiter(this, void 0, void 0, function* () {
1320
+ if (this.logger)
1321
+ this.logger.debug("Calling operation SecurityAttributeClient#listSecurityAttributeWorkRequests.");
1322
+ const operationName = "listSecurityAttributeWorkRequests";
1323
+ const apiReferenceLink = "";
1324
+ const pathParams = {};
1325
+ const queryParams = {
1326
+ "compartmentId": listSecurityAttributeWorkRequestsRequest.compartmentId,
1327
+ "page": listSecurityAttributeWorkRequestsRequest.page,
1328
+ "limit": listSecurityAttributeWorkRequestsRequest.limit,
1329
+ "resourceIdentifier": listSecurityAttributeWorkRequestsRequest.resourceIdentifier
1330
+ };
1331
+ let headerParams = {
1332
+ "Content-Type": common.Constants.APPLICATION_JSON,
1333
+ "opc-request-id": listSecurityAttributeWorkRequestsRequest.opcRequestId
1334
+ };
1335
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
1336
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listSecurityAttributeWorkRequestsRequest.retryConfiguration, specRetryConfiguration);
1337
+ if (this.logger)
1338
+ retrier.logger = this.logger;
1339
+ const request = yield oci_common_2.composeRequest({
1340
+ baseEndpoint: this._endpoint,
1341
+ defaultHeaders: this._defaultHeaders,
1342
+ path: "/securityAttributeWorkRequests",
1343
+ method: "GET",
1344
+ pathParams: pathParams,
1345
+ headerParams: headerParams,
1346
+ queryParams: queryParams
1347
+ });
1348
+ try {
1349
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
1350
+ const sdkResponse = oci_common_2.composeResponse({
1351
+ responseObject: {},
1352
+ body: yield response.json(),
1353
+ bodyKey: "items",
1354
+ bodyModel: model.SecurityAttributeWorkRequestSummary,
1355
+ type: "Array<model.SecurityAttributeWorkRequestSummary>",
1356
+ responseHeaders: [
1357
+ {
1358
+ value: response.headers.get("opc-request-id"),
1359
+ key: "opcRequestId",
1360
+ dataType: "string"
1361
+ },
1362
+ {
1363
+ value: response.headers.get("opc-next-page"),
1364
+ key: "opcNextPage",
1365
+ dataType: "string"
1366
+ }
1367
+ ]
1368
+ });
1369
+ return sdkResponse;
1370
+ }
1371
+ catch (err) {
1372
+ throw err;
1373
+ }
1374
+ });
1375
+ }
1376
+ /**
1377
+ * NOTE: This function is deprecated in favor of listSecurityAttributeWorkRequestsRecordIterator function.
1378
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeWorkRequestSummary objects
1379
+ * contained in responses from the listSecurityAttributeWorkRequests operation. This iterator will fetch more data from the
1380
+ * server as needed.
1381
+ *
1382
+ * @param request a request which can be sent to the service operation
1383
+ */
1384
+ listAllSecurityAttributeWorkRequests(request) {
1385
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributeWorkRequests(req));
1386
+ }
1387
+ /**
1388
+ * NOTE: This function is deprecated in favor of listSecurityAttributeWorkRequestsResponseIterator function.
1389
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributeWorkRequests operation. This iterator
1390
+ * will fetch more data from the server as needed.
1391
+ *
1392
+ * @param request a request which can be sent to the service operation
1393
+ */
1394
+ listAllSecurityAttributeWorkRequestsResponses(request) {
1395
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributeWorkRequests(req));
1396
+ }
1397
+ /**
1398
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeWorkRequestSummary objects
1399
+ * contained in responses from the listSecurityAttributeWorkRequests operation. This iterator will fetch more data from the
1400
+ * server as needed.
1401
+ *
1402
+ * @param request a request which can be sent to the service operation
1403
+ */
1404
+ listSecurityAttributeWorkRequestsRecordIterator(request) {
1405
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributeWorkRequests(req));
1406
+ }
1407
+ /**
1408
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributeWorkRequests operation. This iterator
1409
+ * will fetch more data from the server as needed.
1410
+ *
1411
+ * @param request a request which can be sent to the service operation
1412
+ */
1413
+ listSecurityAttributeWorkRequestsResponseIterator(request) {
1414
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributeWorkRequests(req));
1415
+ }
1416
+ /**
1417
+ * Lists the security attributes in the specified namespace.
1418
+ *
1419
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
1420
+ * @param ListSecurityAttributesRequest
1421
+ * @return ListSecurityAttributesResponse
1422
+ * @throws OciError when an error occurs
1423
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/ListSecurityAttributes.ts.html |here} to see how to use ListSecurityAttributes API.
1424
+ */
1425
+ listSecurityAttributes(listSecurityAttributesRequest) {
1426
+ return __awaiter(this, void 0, void 0, function* () {
1427
+ if (this.logger)
1428
+ this.logger.debug("Calling operation SecurityAttributeClient#listSecurityAttributes.");
1429
+ const operationName = "listSecurityAttributes";
1430
+ const apiReferenceLink = "";
1431
+ const pathParams = {
1432
+ "{securityAttributeNamespaceId}": listSecurityAttributesRequest.securityAttributeNamespaceId
1433
+ };
1434
+ const queryParams = {
1435
+ "page": listSecurityAttributesRequest.page,
1436
+ "limit": listSecurityAttributesRequest.limit,
1437
+ "lifecycleState": listSecurityAttributesRequest.lifecycleState
1438
+ };
1439
+ let headerParams = {
1440
+ "Content-Type": common.Constants.APPLICATION_JSON,
1441
+ "opc-request-id": listSecurityAttributesRequest.opcRequestId
1442
+ };
1443
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
1444
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, listSecurityAttributesRequest.retryConfiguration, specRetryConfiguration);
1445
+ if (this.logger)
1446
+ retrier.logger = this.logger;
1447
+ const request = yield oci_common_2.composeRequest({
1448
+ baseEndpoint: this._endpoint,
1449
+ defaultHeaders: this._defaultHeaders,
1450
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes",
1451
+ method: "GET",
1452
+ pathParams: pathParams,
1453
+ headerParams: headerParams,
1454
+ queryParams: queryParams
1455
+ });
1456
+ try {
1457
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
1458
+ const sdkResponse = oci_common_2.composeResponse({
1459
+ responseObject: {},
1460
+ body: yield response.json(),
1461
+ bodyKey: "items",
1462
+ bodyModel: model.SecurityAttributeSummary,
1463
+ type: "Array<model.SecurityAttributeSummary>",
1464
+ responseHeaders: [
1465
+ {
1466
+ value: response.headers.get("opc-request-id"),
1467
+ key: "opcRequestId",
1468
+ dataType: "string"
1469
+ },
1470
+ {
1471
+ value: response.headers.get("opc-next-page"),
1472
+ key: "opcNextPage",
1473
+ dataType: "string"
1474
+ }
1475
+ ]
1476
+ });
1477
+ return sdkResponse;
1478
+ }
1479
+ catch (err) {
1480
+ throw err;
1481
+ }
1482
+ });
1483
+ }
1484
+ /**
1485
+ * NOTE: This function is deprecated in favor of listSecurityAttributesRecordIterator function.
1486
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeSummary objects
1487
+ * contained in responses from the listSecurityAttributes operation. This iterator will fetch more data from the
1488
+ * server as needed.
1489
+ *
1490
+ * @param request a request which can be sent to the service operation
1491
+ */
1492
+ listAllSecurityAttributes(request) {
1493
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributes(req));
1494
+ }
1495
+ /**
1496
+ * NOTE: This function is deprecated in favor of listSecurityAttributesResponseIterator function.
1497
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributes operation. This iterator
1498
+ * will fetch more data from the server as needed.
1499
+ *
1500
+ * @param request a request which can be sent to the service operation
1501
+ */
1502
+ listAllSecurityAttributesResponses(request) {
1503
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributes(req));
1504
+ }
1505
+ /**
1506
+ * Creates a new async iterator which will iterate over the models.SecurityAttributeSummary objects
1507
+ * contained in responses from the listSecurityAttributes operation. This iterator will fetch more data from the
1508
+ * server as needed.
1509
+ *
1510
+ * @param request a request which can be sent to the service operation
1511
+ */
1512
+ listSecurityAttributesRecordIterator(request) {
1513
+ return oci_common_1.paginateRecords(request, req => this.listSecurityAttributes(req));
1514
+ }
1515
+ /**
1516
+ * Creates a new async iterator which will iterate over the responses received from the listSecurityAttributes operation. This iterator
1517
+ * will fetch more data from the server as needed.
1518
+ *
1519
+ * @param request a request which can be sent to the service operation
1520
+ */
1521
+ listSecurityAttributesResponseIterator(request) {
1522
+ return oci_common_1.paginateResponses(request, req => this.listSecurityAttributes(req));
1523
+ }
1524
+ /**
1525
+ * Updates the specified security attribute. You can only update `description`, and `isRetired`.
1526
+ *
1527
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
1528
+ * @param UpdateSecurityAttributeRequest
1529
+ * @return UpdateSecurityAttributeResponse
1530
+ * @throws OciError when an error occurs
1531
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/UpdateSecurityAttribute.ts.html |here} to see how to use UpdateSecurityAttribute API.
1532
+ */
1533
+ updateSecurityAttribute(updateSecurityAttributeRequest) {
1534
+ return __awaiter(this, void 0, void 0, function* () {
1535
+ if (this.logger)
1536
+ this.logger.debug("Calling operation SecurityAttributeClient#updateSecurityAttribute.");
1537
+ const operationName = "updateSecurityAttribute";
1538
+ const apiReferenceLink = "";
1539
+ const pathParams = {
1540
+ "{securityAttributeNamespaceId}": updateSecurityAttributeRequest.securityAttributeNamespaceId,
1541
+ "{securityAttributeName}": updateSecurityAttributeRequest.securityAttributeName
1542
+ };
1543
+ const queryParams = {};
1544
+ let headerParams = {
1545
+ "Content-Type": common.Constants.APPLICATION_JSON,
1546
+ "if-match": updateSecurityAttributeRequest.ifMatch,
1547
+ "opc-request-id": updateSecurityAttributeRequest.opcRequestId,
1548
+ "opc-retry-token": updateSecurityAttributeRequest.opcRetryToken
1549
+ };
1550
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
1551
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, updateSecurityAttributeRequest.retryConfiguration, specRetryConfiguration);
1552
+ if (this.logger)
1553
+ retrier.logger = this.logger;
1554
+ const request = yield oci_common_2.composeRequest({
1555
+ baseEndpoint: this._endpoint,
1556
+ defaultHeaders: this._defaultHeaders,
1557
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes/{securityAttributeName}",
1558
+ method: "PUT",
1559
+ bodyContent: common.ObjectSerializer.serialize(updateSecurityAttributeRequest.updateSecurityAttributeDetails, "UpdateSecurityAttributeDetails", model.UpdateSecurityAttributeDetails.getJsonObj),
1560
+ pathParams: pathParams,
1561
+ headerParams: headerParams,
1562
+ queryParams: queryParams
1563
+ });
1564
+ try {
1565
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
1566
+ const sdkResponse = oci_common_2.composeResponse({
1567
+ responseObject: {},
1568
+ body: yield response.json(),
1569
+ bodyKey: "securityAttribute",
1570
+ bodyModel: model.SecurityAttribute,
1571
+ type: "model.SecurityAttribute",
1572
+ responseHeaders: [
1573
+ {
1574
+ value: response.headers.get("opc-request-id"),
1575
+ key: "opcRequestId",
1576
+ dataType: "string"
1577
+ },
1578
+ {
1579
+ value: response.headers.get("etag"),
1580
+ key: "etag",
1581
+ dataType: "string"
1582
+ }
1583
+ ]
1584
+ });
1585
+ return sdkResponse;
1586
+ }
1587
+ catch (err) {
1588
+ throw err;
1589
+ }
1590
+ });
1591
+ }
1592
+ /**
1593
+ * Updates the specified security attribute namespace. You can't update the namespace name.
1594
+ * <p>
1595
+ Updating `isRetired` to 'true' retires the namespace and all the security attributes in the namespace. Reactivating a
1596
+ * namespace (changing `isRetired` from 'true' to 'false') does not reactivate security attributes.
1597
+ * To reactivate the security attributes, you must reactivate each one individually *after* you reactivate the namespace,
1598
+ * using {@link #updateTag(UpdateTagRequest) updateTag}. For more information about retiring security attribute namespaces, see
1599
+ * [Managing Security Attribute Namespaces](https://docs.cloud.oracle.com/Content/zero-trust-packet-routing/managing-security-attribute-namespaces.htm).
1600
+ * <p>
1601
+ You can't add a namespace with the same name as a retired namespace in the same tenancy.
1602
+ *
1603
+ * This operation uses {@link common.OciSdkDefaultRetryConfiguration} by default if no retry configuration is defined by the user.
1604
+ * @param UpdateSecurityAttributeNamespaceRequest
1605
+ * @return UpdateSecurityAttributeNamespaceResponse
1606
+ * @throws OciError when an error occurs
1607
+ * @example Click {@link https://docs.cloud.oracle.com/en-us/iaas/tools/typescript-sdk-examples/latest/securityattribute/UpdateSecurityAttributeNamespace.ts.html |here} to see how to use UpdateSecurityAttributeNamespace API.
1608
+ */
1609
+ updateSecurityAttributeNamespace(updateSecurityAttributeNamespaceRequest) {
1610
+ return __awaiter(this, void 0, void 0, function* () {
1611
+ if (this.logger)
1612
+ this.logger.debug("Calling operation SecurityAttributeClient#updateSecurityAttributeNamespace.");
1613
+ const operationName = "updateSecurityAttributeNamespace";
1614
+ const apiReferenceLink = "";
1615
+ const pathParams = {
1616
+ "{securityAttributeNamespaceId}": updateSecurityAttributeNamespaceRequest.securityAttributeNamespaceId
1617
+ };
1618
+ const queryParams = {};
1619
+ let headerParams = {
1620
+ "Content-Type": common.Constants.APPLICATION_JSON,
1621
+ "if-match": updateSecurityAttributeNamespaceRequest.ifMatch,
1622
+ "opc-request-id": updateSecurityAttributeNamespaceRequest.opcRequestId,
1623
+ "opc-retry-token": updateSecurityAttributeNamespaceRequest.opcRetryToken
1624
+ };
1625
+ const specRetryConfiguration = common.OciSdkDefaultRetryConfiguration;
1626
+ const retrier = oci_common_2.GenericRetrier.createPreferredRetrier(this._clientConfiguration ? this._clientConfiguration.retryConfiguration : undefined, updateSecurityAttributeNamespaceRequest.retryConfiguration, specRetryConfiguration);
1627
+ if (this.logger)
1628
+ retrier.logger = this.logger;
1629
+ const request = yield oci_common_2.composeRequest({
1630
+ baseEndpoint: this._endpoint,
1631
+ defaultHeaders: this._defaultHeaders,
1632
+ path: "/securityAttributeNamespaces/{securityAttributeNamespaceId}",
1633
+ method: "PUT",
1634
+ bodyContent: common.ObjectSerializer.serialize(updateSecurityAttributeNamespaceRequest.updateSecurityAttributeNamespaceDetails, "UpdateSecurityAttributeNamespaceDetails", model.UpdateSecurityAttributeNamespaceDetails.getJsonObj),
1635
+ pathParams: pathParams,
1636
+ headerParams: headerParams,
1637
+ queryParams: queryParams
1638
+ });
1639
+ try {
1640
+ const response = yield retrier.makeServiceCall(this._httpClient, request, this.targetService, operationName, apiReferenceLink);
1641
+ const sdkResponse = oci_common_2.composeResponse({
1642
+ responseObject: {},
1643
+ body: yield response.json(),
1644
+ bodyKey: "securityAttributeNamespace",
1645
+ bodyModel: model.SecurityAttributeNamespace,
1646
+ type: "model.SecurityAttributeNamespace",
1647
+ responseHeaders: [
1648
+ {
1649
+ value: response.headers.get("opc-request-id"),
1650
+ key: "opcRequestId",
1651
+ dataType: "string"
1652
+ },
1653
+ {
1654
+ value: response.headers.get("etag"),
1655
+ key: "etag",
1656
+ dataType: "string"
1657
+ }
1658
+ ]
1659
+ });
1660
+ return sdkResponse;
1661
+ }
1662
+ catch (err) {
1663
+ throw err;
1664
+ }
1665
+ });
1666
+ }
1667
+ }
1668
+ exports.SecurityAttributeClient = SecurityAttributeClient;
1669
+ SecurityAttributeClient.serviceEndpointTemplate = "https://security-attribute.{region}.oci.{secondLevelDomain}";
1670
+ SecurityAttributeClient.endpointServiceName = "";
1671
+ //# sourceMappingURL=client.js.map