| OLD | NEW |
| 1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
| 2 | 2 |
| 3 library googleapis.servicemanagement.v1; | 3 library googleapis.servicemanagement.v1; |
| 4 | 4 |
| 5 import 'dart:core' as core; | 5 import 'dart:core' as core; |
| 6 import 'dart:async' as async; | 6 import 'dart:async' as async; |
| 7 import 'dart:convert' as convert; | 7 import 'dart:convert' as convert; |
| 8 | 8 |
| 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
| 10 import 'package:http/http.dart' as http_1; | 10 import 'package:http/http.dart' as http_1; |
| (...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 383 | 383 |
| 384 /** | 384 /** |
| 385 * Gets a service configuration (version) for a managed service. | 385 * Gets a service configuration (version) for a managed service. |
| 386 * | 386 * |
| 387 * Request parameters: | 387 * Request parameters: |
| 388 * | 388 * |
| 389 * [serviceName] - The name of the service. See the | 389 * [serviceName] - The name of the service. See the |
| 390 * [overview](/service-management/overview) | 390 * [overview](/service-management/overview) |
| 391 * for naming requirements. For example: `example.googleapis.com`. | 391 * for naming requirements. For example: `example.googleapis.com`. |
| 392 * | 392 * |
| 393 * [view] - Specifies which parts of the Service Config should be returned in |
| 394 * the |
| 395 * response. |
| 396 * Possible string values are: |
| 397 * - "BASIC" : A BASIC. |
| 398 * - "FULL" : A FULL. |
| 399 * |
| 393 * [configId] - The id of the service configuration resource. | 400 * [configId] - The id of the service configuration resource. |
| 394 * | 401 * |
| 395 * Completes with a [Service]. | 402 * Completes with a [Service]. |
| 396 * | 403 * |
| 397 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 404 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 398 * error. | 405 * error. |
| 399 * | 406 * |
| 400 * If the used [http_1.Client] completes with an error when making a REST | 407 * If the used [http_1.Client] completes with an error when making a REST |
| 401 * call, this method will complete with the same error. | 408 * call, this method will complete with the same error. |
| 402 */ | 409 */ |
| 403 async.Future<Service> getConfig(core.String serviceName, {core.String configId
}) { | 410 async.Future<Service> getConfig(core.String serviceName, {core.String view, co
re.String configId}) { |
| 404 var _url = null; | 411 var _url = null; |
| 405 var _queryParams = new core.Map(); | 412 var _queryParams = new core.Map(); |
| 406 var _uploadMedia = null; | 413 var _uploadMedia = null; |
| 407 var _uploadOptions = null; | 414 var _uploadOptions = null; |
| 408 var _downloadOptions = commons.DownloadOptions.Metadata; | 415 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 409 var _body = null; | 416 var _body = null; |
| 410 | 417 |
| 411 if (serviceName == null) { | 418 if (serviceName == null) { |
| 412 throw new core.ArgumentError("Parameter serviceName is required."); | 419 throw new core.ArgumentError("Parameter serviceName is required."); |
| 413 } | 420 } |
| 421 if (view != null) { |
| 422 _queryParams["view"] = [view]; |
| 423 } |
| 414 if (configId != null) { | 424 if (configId != null) { |
| 415 _queryParams["configId"] = [configId]; | 425 _queryParams["configId"] = [configId]; |
| 416 } | 426 } |
| 417 | 427 |
| 418 _url = 'v1/services/' + commons.Escaper.ecapeVariable('$serviceName') + '/co
nfig'; | 428 _url = 'v1/services/' + commons.Escaper.ecapeVariable('$serviceName') + '/co
nfig'; |
| 419 | 429 |
| 420 var _response = _requester.request(_url, | 430 var _response = _requester.request(_url, |
| 421 "GET", | 431 "GET", |
| 422 body: _body, | 432 body: _body, |
| 423 queryParams: _queryParams, | 433 queryParams: _queryParams, |
| 424 uploadOptions: _uploadOptions, | 434 uploadOptions: _uploadOptions, |
| 425 uploadMedia: _uploadMedia, | 435 uploadMedia: _uploadMedia, |
| 426 downloadOptions: _downloadOptions); | 436 downloadOptions: _downloadOptions); |
| 427 return _response.then((data) => new Service.fromJson(data)); | 437 return _response.then((data) => new Service.fromJson(data)); |
| 428 } | 438 } |
| 429 | 439 |
| 430 /** | 440 /** |
| 431 * Gets the access control policy for a resource. | 441 * Gets the access control policy for a resource. |
| 432 * Returns an empty policy if the resource exists and does not have a policy | 442 * Returns an empty policy if the resource exists and does not have a policy |
| 433 * set. | 443 * set. |
| 434 * | 444 * |
| 435 * [request] - The metadata request object. | 445 * [request] - The metadata request object. |
| 436 * | 446 * |
| 437 * Request parameters: | 447 * Request parameters: |
| 438 * | 448 * |
| 439 * [resource] - REQUIRED: The resource for which the policy is being | 449 * [resource] - REQUIRED: The resource for which the policy is being |
| 440 * requested. | 450 * requested. |
| 441 * `resource` is usually specified as a path. For example, a Project | 451 * See the operation documentation for the appropriate value for this field. |
| 442 * resource is specified as `projects/{project}`. | |
| 443 * Value must have pattern "^services/[^/]+$". | 452 * Value must have pattern "^services/[^/]+$". |
| 444 * | 453 * |
| 445 * Completes with a [Policy]. | 454 * Completes with a [Policy]. |
| 446 * | 455 * |
| 447 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 456 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 448 * error. | 457 * error. |
| 449 * | 458 * |
| 450 * If the used [http_1.Client] completes with an error when making a REST | 459 * If the used [http_1.Client] completes with an error when making a REST |
| 451 * call, this method will complete with the same error. | 460 * call, this method will complete with the same error. |
| 452 */ | 461 */ |
| (...skipping 20 matching lines...) Expand all Loading... |
| 473 queryParams: _queryParams, | 482 queryParams: _queryParams, |
| 474 uploadOptions: _uploadOptions, | 483 uploadOptions: _uploadOptions, |
| 475 uploadMedia: _uploadMedia, | 484 uploadMedia: _uploadMedia, |
| 476 downloadOptions: _downloadOptions); | 485 downloadOptions: _downloadOptions); |
| 477 return _response.then((data) => new Policy.fromJson(data)); | 486 return _response.then((data) => new Policy.fromJson(data)); |
| 478 } | 487 } |
| 479 | 488 |
| 480 /** | 489 /** |
| 481 * Lists managed services. | 490 * Lists managed services. |
| 482 * | 491 * |
| 483 * If called without any authentication, it returns only the public services. | 492 * Returns all public services. For authenticated users, also returns all |
| 484 * If called with authentication, it returns all services that the caller has | 493 * services the calling user has "servicemanagement.services.get" permission |
| 485 * "servicemanagement.services.get" permission for. | 494 * for. |
| 486 * | 495 * |
| 487 * **BETA:** If the caller specifies the `consumer_id`, it returns only the | 496 * **BETA:** If the caller specifies the `consumer_id`, it returns only the |
| 488 * services enabled on the consumer. The `consumer_id` must have the format | 497 * services enabled on the consumer. The `consumer_id` must have the format |
| 489 * of "project:{PROJECT-ID}". | 498 * of "project:{PROJECT-ID}". |
| 490 * | 499 * |
| 491 * Request parameters: | 500 * Request parameters: |
| 492 * | 501 * |
| 493 * [consumerId] - Include services consumed by the specified consumer. | 502 * [consumerId] - Include services consumed by the specified consumer. |
| 494 * | 503 * |
| 495 * The Google Service Management implementation accepts the following | 504 * The Google Service Management implementation accepts the following |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 548 /** | 557 /** |
| 549 * Sets the access control policy on the specified resource. Replaces any | 558 * Sets the access control policy on the specified resource. Replaces any |
| 550 * existing policy. | 559 * existing policy. |
| 551 * | 560 * |
| 552 * [request] - The metadata request object. | 561 * [request] - The metadata request object. |
| 553 * | 562 * |
| 554 * Request parameters: | 563 * Request parameters: |
| 555 * | 564 * |
| 556 * [resource] - REQUIRED: The resource for which the policy is being | 565 * [resource] - REQUIRED: The resource for which the policy is being |
| 557 * specified. | 566 * specified. |
| 558 * `resource` is usually specified as a path. For example, a Project | 567 * See the operation documentation for the appropriate value for this field. |
| 559 * resource is specified as `projects/{project}`. | |
| 560 * Value must have pattern "^services/[^/]+$". | 568 * Value must have pattern "^services/[^/]+$". |
| 561 * | 569 * |
| 562 * Completes with a [Policy]. | 570 * Completes with a [Policy]. |
| 563 * | 571 * |
| 564 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 572 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 565 * error. | 573 * error. |
| 566 * | 574 * |
| 567 * If the used [http_1.Client] completes with an error when making a REST | 575 * If the used [http_1.Client] completes with an error when making a REST |
| 568 * call, this method will complete with the same error. | 576 * call, this method will complete with the same error. |
| 569 */ | 577 */ |
| (...skipping 22 matching lines...) Expand all Loading... |
| 592 uploadMedia: _uploadMedia, | 600 uploadMedia: _uploadMedia, |
| 593 downloadOptions: _downloadOptions); | 601 downloadOptions: _downloadOptions); |
| 594 return _response.then((data) => new Policy.fromJson(data)); | 602 return _response.then((data) => new Policy.fromJson(data)); |
| 595 } | 603 } |
| 596 | 604 |
| 597 /** | 605 /** |
| 598 * Returns permissions that a caller has on the specified resource. | 606 * Returns permissions that a caller has on the specified resource. |
| 599 * If the resource does not exist, this will return an empty set of | 607 * If the resource does not exist, this will return an empty set of |
| 600 * permissions, not a NOT_FOUND error. | 608 * permissions, not a NOT_FOUND error. |
| 601 * | 609 * |
| 610 * Note: This operation is designed to be used for building permission-aware |
| 611 * UIs and command-line tools, not for authorization checking. This operation |
| 612 * may "fail open" without warning. |
| 613 * |
| 602 * [request] - The metadata request object. | 614 * [request] - The metadata request object. |
| 603 * | 615 * |
| 604 * Request parameters: | 616 * Request parameters: |
| 605 * | 617 * |
| 606 * [resource] - REQUIRED: The resource for which the policy detail is being | 618 * [resource] - REQUIRED: The resource for which the policy detail is being |
| 607 * requested. | 619 * requested. |
| 608 * `resource` is usually specified as a path. For example, a Project | 620 * See the operation documentation for the appropriate value for this field. |
| 609 * resource is specified as `projects/{project}`. | |
| 610 * Value must have pattern "^services/[^/]+$". | 621 * Value must have pattern "^services/[^/]+$". |
| 611 * | 622 * |
| 612 * Completes with a [TestIamPermissionsResponse]. | 623 * Completes with a [TestIamPermissionsResponse]. |
| 613 * | 624 * |
| 614 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 625 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 615 * error. | 626 * error. |
| 616 * | 627 * |
| 617 * If the used [http_1.Client] completes with an error when making a REST | 628 * If the used [http_1.Client] completes with an error when making a REST |
| 618 * call, this method will complete with the same error. | 629 * call, this method will complete with the same error. |
| 619 */ | 630 */ |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 752 * Gets a service configuration (version) for a managed service. | 763 * Gets a service configuration (version) for a managed service. |
| 753 * | 764 * |
| 754 * Request parameters: | 765 * Request parameters: |
| 755 * | 766 * |
| 756 * [serviceName] - The name of the service. See the | 767 * [serviceName] - The name of the service. See the |
| 757 * [overview](/service-management/overview) | 768 * [overview](/service-management/overview) |
| 758 * for naming requirements. For example: `example.googleapis.com`. | 769 * for naming requirements. For example: `example.googleapis.com`. |
| 759 * | 770 * |
| 760 * [configId] - The id of the service configuration resource. | 771 * [configId] - The id of the service configuration resource. |
| 761 * | 772 * |
| 773 * [view] - Specifies which parts of the Service Config should be returned in |
| 774 * the |
| 775 * response. |
| 776 * Possible string values are: |
| 777 * - "BASIC" : A BASIC. |
| 778 * - "FULL" : A FULL. |
| 779 * |
| 762 * Completes with a [Service]. | 780 * Completes with a [Service]. |
| 763 * | 781 * |
| 764 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 782 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 765 * error. | 783 * error. |
| 766 * | 784 * |
| 767 * If the used [http_1.Client] completes with an error when making a REST | 785 * If the used [http_1.Client] completes with an error when making a REST |
| 768 * call, this method will complete with the same error. | 786 * call, this method will complete with the same error. |
| 769 */ | 787 */ |
| 770 async.Future<Service> get(core.String serviceName, core.String configId) { | 788 async.Future<Service> get(core.String serviceName, core.String configId, {core
.String view}) { |
| 771 var _url = null; | 789 var _url = null; |
| 772 var _queryParams = new core.Map(); | 790 var _queryParams = new core.Map(); |
| 773 var _uploadMedia = null; | 791 var _uploadMedia = null; |
| 774 var _uploadOptions = null; | 792 var _uploadOptions = null; |
| 775 var _downloadOptions = commons.DownloadOptions.Metadata; | 793 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 776 var _body = null; | 794 var _body = null; |
| 777 | 795 |
| 778 if (serviceName == null) { | 796 if (serviceName == null) { |
| 779 throw new core.ArgumentError("Parameter serviceName is required."); | 797 throw new core.ArgumentError("Parameter serviceName is required."); |
| 780 } | 798 } |
| 781 if (configId == null) { | 799 if (configId == null) { |
| 782 throw new core.ArgumentError("Parameter configId is required."); | 800 throw new core.ArgumentError("Parameter configId is required."); |
| 783 } | 801 } |
| 802 if (view != null) { |
| 803 _queryParams["view"] = [view]; |
| 804 } |
| 784 | 805 |
| 785 _url = 'v1/services/' + commons.Escaper.ecapeVariable('$serviceName') + '/co
nfigs/' + commons.Escaper.ecapeVariable('$configId'); | 806 _url = 'v1/services/' + commons.Escaper.ecapeVariable('$serviceName') + '/co
nfigs/' + commons.Escaper.ecapeVariable('$configId'); |
| 786 | 807 |
| 787 var _response = _requester.request(_url, | 808 var _response = _requester.request(_url, |
| 788 "GET", | 809 "GET", |
| 789 body: _body, | 810 body: _body, |
| 790 queryParams: _queryParams, | 811 queryParams: _queryParams, |
| 791 uploadOptions: _uploadOptions, | 812 uploadOptions: _uploadOptions, |
| 792 uploadMedia: _uploadMedia, | 813 uploadMedia: _uploadMedia, |
| 793 downloadOptions: _downloadOptions); | 814 downloadOptions: _downloadOptions); |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1013 /** | 1034 /** |
| 1014 * Lists the history of the service configuration rollouts for a managed | 1035 * Lists the history of the service configuration rollouts for a managed |
| 1015 * service, from the newest to the oldest. | 1036 * service, from the newest to the oldest. |
| 1016 * | 1037 * |
| 1017 * Request parameters: | 1038 * Request parameters: |
| 1018 * | 1039 * |
| 1019 * [serviceName] - The name of the service. See the | 1040 * [serviceName] - The name of the service. See the |
| 1020 * [overview](/service-management/overview) | 1041 * [overview](/service-management/overview) |
| 1021 * for naming requirements. For example: `example.googleapis.com`. | 1042 * for naming requirements. For example: `example.googleapis.com`. |
| 1022 * | 1043 * |
| 1044 * [pageSize] - The max number of items to include in the response list. |
| 1045 * |
| 1023 * [pageToken] - The token of the page to retrieve. | 1046 * [pageToken] - The token of the page to retrieve. |
| 1024 * | 1047 * |
| 1025 * [pageSize] - The max number of items to include in the response list. | |
| 1026 * | |
| 1027 * Completes with a [ListServiceRolloutsResponse]. | 1048 * Completes with a [ListServiceRolloutsResponse]. |
| 1028 * | 1049 * |
| 1029 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 1050 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| 1030 * error. | 1051 * error. |
| 1031 * | 1052 * |
| 1032 * If the used [http_1.Client] completes with an error when making a REST | 1053 * If the used [http_1.Client] completes with an error when making a REST |
| 1033 * call, this method will complete with the same error. | 1054 * call, this method will complete with the same error. |
| 1034 */ | 1055 */ |
| 1035 async.Future<ListServiceRolloutsResponse> list(core.String serviceName, {core.
String pageToken, core.int pageSize}) { | 1056 async.Future<ListServiceRolloutsResponse> list(core.String serviceName, {core.
int pageSize, core.String pageToken}) { |
| 1036 var _url = null; | 1057 var _url = null; |
| 1037 var _queryParams = new core.Map(); | 1058 var _queryParams = new core.Map(); |
| 1038 var _uploadMedia = null; | 1059 var _uploadMedia = null; |
| 1039 var _uploadOptions = null; | 1060 var _uploadOptions = null; |
| 1040 var _downloadOptions = commons.DownloadOptions.Metadata; | 1061 var _downloadOptions = commons.DownloadOptions.Metadata; |
| 1041 var _body = null; | 1062 var _body = null; |
| 1042 | 1063 |
| 1043 if (serviceName == null) { | 1064 if (serviceName == null) { |
| 1044 throw new core.ArgumentError("Parameter serviceName is required."); | 1065 throw new core.ArgumentError("Parameter serviceName is required."); |
| 1045 } | 1066 } |
| 1067 if (pageSize != null) { |
| 1068 _queryParams["pageSize"] = ["${pageSize}"]; |
| 1069 } |
| 1046 if (pageToken != null) { | 1070 if (pageToken != null) { |
| 1047 _queryParams["pageToken"] = [pageToken]; | 1071 _queryParams["pageToken"] = [pageToken]; |
| 1048 } | 1072 } |
| 1049 if (pageSize != null) { | |
| 1050 _queryParams["pageSize"] = ["${pageSize}"]; | |
| 1051 } | |
| 1052 | 1073 |
| 1053 _url = 'v1/services/' + commons.Escaper.ecapeVariable('$serviceName') + '/ro
llouts'; | 1074 _url = 'v1/services/' + commons.Escaper.ecapeVariable('$serviceName') + '/ro
llouts'; |
| 1054 | 1075 |
| 1055 var _response = _requester.request(_url, | 1076 var _response = _requester.request(_url, |
| 1056 "GET", | 1077 "GET", |
| 1057 body: _body, | 1078 body: _body, |
| 1058 queryParams: _queryParams, | 1079 queryParams: _queryParams, |
| 1059 uploadOptions: _uploadOptions, | 1080 uploadOptions: _uploadOptions, |
| 1060 uploadMedia: _uploadMedia, | 1081 uploadMedia: _uploadMedia, |
| 1061 downloadOptions: _downloadOptions); | 1082 downloadOptions: _downloadOptions); |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1194 } | 1215 } |
| 1195 return _json; | 1216 return _json; |
| 1196 } | 1217 } |
| 1197 } | 1218 } |
| 1198 | 1219 |
| 1199 /** | 1220 /** |
| 1200 * Specifies the audit configuration for a service. | 1221 * Specifies the audit configuration for a service. |
| 1201 * It consists of which permission types are logged, and what identities, if | 1222 * It consists of which permission types are logged, and what identities, if |
| 1202 * any, are exempted from logging. | 1223 * any, are exempted from logging. |
| 1203 * An AuditConifg must have one or more AuditLogConfigs. | 1224 * An AuditConifg must have one or more AuditLogConfigs. |
| 1225 * |
| 1226 * If there are AuditConfigs for both `allServices` and a specific service, |
| 1227 * the union of the two AuditConfigs is used for that service: the log_types |
| 1228 * specified in each AuditConfig are enabled, and the exempted_members in each |
| 1229 * AuditConfig are exempted. |
| 1230 * Example Policy with multiple AuditConfigs: |
| 1231 * { |
| 1232 * "audit_configs": [ |
| 1233 * { |
| 1234 * "service": "allServices" |
| 1235 * "audit_log_configs": [ |
| 1236 * { |
| 1237 * "log_type": "DATA_READ", |
| 1238 * "exempted_members": [ |
| 1239 * "user:foo@gmail.com" |
| 1240 * ] |
| 1241 * }, |
| 1242 * { |
| 1243 * "log_type": "DATA_WRITE", |
| 1244 * }, |
| 1245 * { |
| 1246 * "log_type": "ADMIN_READ", |
| 1247 * } |
| 1248 * ] |
| 1249 * }, |
| 1250 * { |
| 1251 * "service": "fooservice@googleapis.com" |
| 1252 * "audit_log_configs": [ |
| 1253 * { |
| 1254 * "log_type": "DATA_READ", |
| 1255 * }, |
| 1256 * { |
| 1257 * "log_type": "DATA_WRITE", |
| 1258 * "exempted_members": [ |
| 1259 * "user:bar@gmail.com" |
| 1260 * ] |
| 1261 * } |
| 1262 * ] |
| 1263 * } |
| 1264 * ] |
| 1265 * } |
| 1266 * For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ |
| 1267 * logging. It also exempts foo@gmail.com from DATA_READ logging, and |
| 1268 * bar@gmail.com from DATA_WRITE logging. |
| 1204 */ | 1269 */ |
| 1205 class AuditConfig { | 1270 class AuditConfig { |
| 1206 /** | 1271 /** |
| 1207 * The configuration for logging of each type of permission. | 1272 * The configuration for logging of each type of permission. |
| 1208 * Next ID: 4 | 1273 * Next ID: 4 |
| 1209 */ | 1274 */ |
| 1210 core.List<AuditLogConfig> auditLogConfigs; | 1275 core.List<AuditLogConfig> auditLogConfigs; |
| 1211 /** | |
| 1212 * Specifies the identities that are exempted from "data access" audit | |
| 1213 * logging for the `service` specified above. | |
| 1214 * Follows the same format of Binding.members. | |
| 1215 * This field is deprecated in favor of per-permission-type exemptions. | |
| 1216 */ | |
| 1217 core.List<core.String> exemptedMembers; | 1276 core.List<core.String> exemptedMembers; |
| 1218 /** | 1277 /** |
| 1219 * Specifies a service that will be enabled for audit logging. | 1278 * Specifies a service that will be enabled for audit logging. |
| 1220 * For example, `resourcemanager`, `storage`, `compute`. | 1279 * For example, `resourcemanager`, `storage`, `compute`. |
| 1221 * `allServices` is a special value that covers all services. | 1280 * `allServices` is a special value that covers all services. |
| 1222 */ | 1281 */ |
| 1223 core.String service; | 1282 core.String service; |
| 1224 | 1283 |
| 1225 AuditConfig(); | 1284 AuditConfig(); |
| 1226 | 1285 |
| (...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1568 if (requirements != null) { | 1627 if (requirements != null) { |
| 1569 _json["requirements"] = requirements.map((value) => (value).toJson()).toLi
st(); | 1628 _json["requirements"] = requirements.map((value) => (value).toJson()).toLi
st(); |
| 1570 } | 1629 } |
| 1571 if (selector != null) { | 1630 if (selector != null) { |
| 1572 _json["selector"] = selector; | 1631 _json["selector"] = selector; |
| 1573 } | 1632 } |
| 1574 return _json; | 1633 return _json; |
| 1575 } | 1634 } |
| 1576 } | 1635 } |
| 1577 | 1636 |
| 1637 /** |
| 1638 * Configuration of authorization. |
| 1639 * |
| 1640 * This section determines the authorization provider, if unspecified, then no |
| 1641 * authorization check will be done. |
| 1642 * |
| 1643 * Example: |
| 1644 * |
| 1645 * experimental: |
| 1646 * authorization: |
| 1647 * provider: firebaserules.googleapis.com |
| 1648 */ |
| 1649 class AuthorizationConfig { |
| 1650 /** |
| 1651 * The name of the authorization provider, such as |
| 1652 * firebaserules.googleapis.com. |
| 1653 */ |
| 1654 core.String provider; |
| 1655 |
| 1656 AuthorizationConfig(); |
| 1657 |
| 1658 AuthorizationConfig.fromJson(core.Map _json) { |
| 1659 if (_json.containsKey("provider")) { |
| 1660 provider = _json["provider"]; |
| 1661 } |
| 1662 } |
| 1663 |
| 1664 core.Map toJson() { |
| 1665 var _json = new core.Map(); |
| 1666 if (provider != null) { |
| 1667 _json["provider"] = provider; |
| 1668 } |
| 1669 return _json; |
| 1670 } |
| 1671 } |
| 1672 |
| 1578 /** `Backend` defines the backend configuration for a service. */ | 1673 /** `Backend` defines the backend configuration for a service. */ |
| 1579 class Backend { | 1674 class Backend { |
| 1580 /** | 1675 /** |
| 1581 * A list of API backend rules that apply to individual API methods. | 1676 * A list of API backend rules that apply to individual API methods. |
| 1582 * | 1677 * |
| 1583 * **NOTE:** All service configuration rules follow "last one wins" order. | 1678 * **NOTE:** All service configuration rules follow "last one wins" order. |
| 1584 */ | 1679 */ |
| 1585 core.List<BackendRule> rules; | 1680 core.List<BackendRule> rules; |
| 1586 | 1681 |
| 1587 Backend(); | 1682 Backend(); |
| (...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1752 /** A condition to be met. */ | 1847 /** A condition to be met. */ |
| 1753 class Condition { | 1848 class Condition { |
| 1754 /** | 1849 /** |
| 1755 * Trusted attributes supplied by the IAM system. | 1850 * Trusted attributes supplied by the IAM system. |
| 1756 * Possible string values are: | 1851 * Possible string values are: |
| 1757 * - "NO_ATTR" : Default non-attribute. | 1852 * - "NO_ATTR" : Default non-attribute. |
| 1758 * - "AUTHORITY" : Either principal or (if present) authority selector. | 1853 * - "AUTHORITY" : Either principal or (if present) authority selector. |
| 1759 * - "ATTRIBUTION" : The principal (even if an authority selector is present), | 1854 * - "ATTRIBUTION" : The principal (even if an authority selector is present), |
| 1760 * which | 1855 * which |
| 1761 * must only be used for attribution, not authorization. | 1856 * must only be used for attribution, not authorization. |
| 1857 * - "APPROVER" : An approver (distinct from the requester) that has |
| 1858 * authorized this |
| 1859 * request. |
| 1860 * When used with IN, the condition indicates that one of the approvers |
| 1861 * associated with the request matches the specified principal, or is a |
| 1862 * member of the specified group. Approvers can only grant additional |
| 1863 * access, and are thus only used in a strictly positive context |
| 1864 * (e.g. ALLOW/IN or DENY/NOT_IN). |
| 1865 * See: go/rpc-security-policy-dynamicauth. |
| 1866 * - "JUSTIFICATION_TYPE" : What types of justifications have been supplied |
| 1867 * with this request. |
| 1868 * String values should match enum names from tech.iam.JustificationType, |
| 1869 * e.g. "MANUAL_STRING". It is not permitted to grant access based on |
| 1870 * the *absence* of a justification, so justification conditions can only |
| 1871 * be used in a "positive" context (e.g., ALLOW/IN or DENY/NOT_IN). |
| 1872 * |
| 1873 * Multiple justifications, e.g., a Buganizer ID and a manually-entered |
| 1874 * reason, are normal and supported. |
| 1762 */ | 1875 */ |
| 1763 core.String iam; | 1876 core.String iam; |
| 1764 /** | 1877 /** |
| 1765 * An operator to apply the subject with. | 1878 * An operator to apply the subject with. |
| 1766 * Possible string values are: | 1879 * Possible string values are: |
| 1767 * - "NO_OP" : Default no-op. | 1880 * - "NO_OP" : Default no-op. |
| 1768 * - "EQUALS" : DEPRECATED. Use IN instead. | 1881 * - "EQUALS" : DEPRECATED. Use IN instead. |
| 1769 * - "NOT_EQUALS" : DEPRECATED. Use NOT_IN instead. | 1882 * - "NOT_EQUALS" : DEPRECATED. Use NOT_IN instead. |
| 1770 * - "IN" : Set-inclusion check. | 1883 * - "IN" : The condition is true if the subject (or any element of it if it |
| 1771 * - "NOT_IN" : Set-exclusion check. | 1884 * is |
| 1885 * a set) matches any of the supplied values. |
| 1886 * - "NOT_IN" : The condition is true if the subject (or every element of it |
| 1887 * if it is |
| 1888 * a set) matches none of the supplied values. |
| 1772 * - "DISCHARGED" : Subject is discharged | 1889 * - "DISCHARGED" : Subject is discharged |
| 1773 */ | 1890 */ |
| 1774 core.String op; | 1891 core.String op; |
| 1775 /** Trusted attributes discharged by the service. */ | 1892 /** Trusted attributes discharged by the service. */ |
| 1776 core.String svc; | 1893 core.String svc; |
| 1777 /** | 1894 /** |
| 1778 * Trusted attributes supplied by any service that owns resources and uses | 1895 * Trusted attributes supplied by any service that owns resources and uses |
| 1779 * the IAM system for access control. | 1896 * the IAM system for access control. |
| 1780 * Possible string values are: | 1897 * Possible string values are: |
| 1781 * - "NO_ATTR" : Default non-attribute type | 1898 * - "NO_ATTR" : Default non-attribute type |
| (...skipping 1029 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2811 if (number != null) { | 2928 if (number != null) { |
| 2812 _json["number"] = number; | 2929 _json["number"] = number; |
| 2813 } | 2930 } |
| 2814 if (options != null) { | 2931 if (options != null) { |
| 2815 _json["options"] = options.map((value) => (value).toJson()).toList(); | 2932 _json["options"] = options.map((value) => (value).toJson()).toList(); |
| 2816 } | 2933 } |
| 2817 return _json; | 2934 return _json; |
| 2818 } | 2935 } |
| 2819 } | 2936 } |
| 2820 | 2937 |
| 2938 /** |
| 2939 * Experimental service configuration. These configuration options can |
| 2940 * only be used by whitelisted users. |
| 2941 */ |
| 2942 class Experimental { |
| 2943 /** Authorization configuration. */ |
| 2944 AuthorizationConfig authorization; |
| 2945 |
| 2946 Experimental(); |
| 2947 |
| 2948 Experimental.fromJson(core.Map _json) { |
| 2949 if (_json.containsKey("authorization")) { |
| 2950 authorization = new AuthorizationConfig.fromJson(_json["authorization"]); |
| 2951 } |
| 2952 } |
| 2953 |
| 2954 core.Map toJson() { |
| 2955 var _json = new core.Map(); |
| 2956 if (authorization != null) { |
| 2957 _json["authorization"] = (authorization).toJson(); |
| 2958 } |
| 2959 return _json; |
| 2960 } |
| 2961 } |
| 2962 |
| 2821 /** A single field of a message type. */ | 2963 /** A single field of a message type. */ |
| 2822 class Field { | 2964 class Field { |
| 2823 /** | 2965 /** |
| 2824 * The field cardinality. | 2966 * The field cardinality. |
| 2825 * Possible string values are: | 2967 * Possible string values are: |
| 2826 * - "CARDINALITY_UNKNOWN" : For fields with unknown cardinality. | 2968 * - "CARDINALITY_UNKNOWN" : For fields with unknown cardinality. |
| 2827 * - "CARDINALITY_OPTIONAL" : For optional fields. | 2969 * - "CARDINALITY_OPTIONAL" : For optional fields. |
| 2828 * - "CARDINALITY_REQUIRED" : For required fields. Proto2 syntax only. | 2970 * - "CARDINALITY_REQUIRED" : For required fields. Proto2 syntax only. |
| 2829 * - "CARDINALITY_REPEATED" : For repeated fields. | 2971 * - "CARDINALITY_REPEATED" : For repeated fields. |
| 2830 */ | 2972 */ |
| (...skipping 492 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3323 * present at the top-level of request message type. | 3465 * present at the top-level of request message type. |
| 3324 */ | 3466 */ |
| 3325 core.String body; | 3467 core.String body; |
| 3326 /** Custom pattern is used for defining custom verbs. */ | 3468 /** Custom pattern is used for defining custom verbs. */ |
| 3327 CustomHttpPattern custom; | 3469 CustomHttpPattern custom; |
| 3328 /** Used for deleting a resource. */ | 3470 /** Used for deleting a resource. */ |
| 3329 core.String delete; | 3471 core.String delete; |
| 3330 /** Used for listing and getting information about resources. */ | 3472 /** Used for listing and getting information about resources. */ |
| 3331 core.String get; | 3473 core.String get; |
| 3332 /** | 3474 /** |
| 3333 * Do not use this. For media support, add instead | 3475 * Use this only for Scotty Requests. Do not use this for bytestream methods. |
| 3334 * [][google.bytestream.RestByteStream] as an API to your | 3476 * For media support, add instead [][google.bytestream.RestByteStream] as an |
| 3335 * configuration. | 3477 * API to your configuration. |
| 3336 */ | 3478 */ |
| 3337 MediaDownload mediaDownload; | 3479 MediaDownload mediaDownload; |
| 3338 /** | 3480 /** |
| 3339 * Do not use this. For media support, add instead | 3481 * Use this only for Scotty Requests. Do not use this for media support using |
| 3482 * Bytestream, add instead |
| 3340 * [][google.bytestream.RestByteStream] as an API to your | 3483 * [][google.bytestream.RestByteStream] as an API to your |
| 3341 * configuration. | 3484 * configuration for Bytestream methods. |
| 3342 */ | 3485 */ |
| 3343 MediaUpload mediaUpload; | 3486 MediaUpload mediaUpload; |
| 3344 /** Used for updating a resource. */ | 3487 /** Used for updating a resource. */ |
| 3345 core.String patch; | 3488 core.String patch; |
| 3346 /** Used for creating a resource. */ | 3489 /** Used for creating a resource. */ |
| 3347 core.String post; | 3490 core.String post; |
| 3348 /** Used for updating a resource. */ | 3491 /** Used for updating a resource. */ |
| 3349 core.String put; | 3492 core.String put; |
| 3350 /** | 3493 /** |
| 3351 * The name of the response field whose value is mapped to the HTTP body of | 3494 * The name of the response field whose value is mapped to the HTTP body of |
| (...skipping 502 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3854 _json["producerProjectId"] = producerProjectId; | 3997 _json["producerProjectId"] = producerProjectId; |
| 3855 } | 3998 } |
| 3856 if (serviceName != null) { | 3999 if (serviceName != null) { |
| 3857 _json["serviceName"] = serviceName; | 4000 _json["serviceName"] = serviceName; |
| 3858 } | 4001 } |
| 3859 return _json; | 4002 return _json; |
| 3860 } | 4003 } |
| 3861 } | 4004 } |
| 3862 | 4005 |
| 3863 /** | 4006 /** |
| 3864 * Do not use this. For media support, add instead | 4007 * Use this only for Scotty Requests. Do not use this for media support using |
| 3865 * [][google.bytestream.RestByteStream] as an API to your | 4008 * Bytestream, add instead [][google.bytestream.RestByteStream] as an API to |
| 3866 * configuration. | 4009 * your configuration for Bytestream methods. |
| 3867 */ | 4010 */ |
| 3868 class MediaDownload { | 4011 class MediaDownload { |
| 4012 /** |
| 4013 * DO NOT USE THIS FIELD UNTIL THIS WARNING IS REMOVED. |
| 4014 * |
| 4015 * Specify name of the download service if one is used for download. |
| 4016 */ |
| 4017 core.String downloadService; |
| 3869 /** Whether download is enabled. */ | 4018 /** Whether download is enabled. */ |
| 3870 core.bool enabled; | 4019 core.bool enabled; |
| 3871 | 4020 |
| 3872 MediaDownload(); | 4021 MediaDownload(); |
| 3873 | 4022 |
| 3874 MediaDownload.fromJson(core.Map _json) { | 4023 MediaDownload.fromJson(core.Map _json) { |
| 4024 if (_json.containsKey("downloadService")) { |
| 4025 downloadService = _json["downloadService"]; |
| 4026 } |
| 3875 if (_json.containsKey("enabled")) { | 4027 if (_json.containsKey("enabled")) { |
| 3876 enabled = _json["enabled"]; | 4028 enabled = _json["enabled"]; |
| 3877 } | 4029 } |
| 3878 } | 4030 } |
| 3879 | 4031 |
| 3880 core.Map toJson() { | 4032 core.Map toJson() { |
| 3881 var _json = new core.Map(); | 4033 var _json = new core.Map(); |
| 4034 if (downloadService != null) { |
| 4035 _json["downloadService"] = downloadService; |
| 4036 } |
| 3882 if (enabled != null) { | 4037 if (enabled != null) { |
| 3883 _json["enabled"] = enabled; | 4038 _json["enabled"] = enabled; |
| 3884 } | 4039 } |
| 3885 return _json; | 4040 return _json; |
| 3886 } | 4041 } |
| 3887 } | 4042 } |
| 3888 | 4043 |
| 3889 /** | 4044 /** |
| 3890 * Do not use this. For media support, add instead | 4045 * Use this only for Scotty Requests. Do not use this for media support using |
| 3891 * [][google.bytestream.RestByteStream] as an API to your | 4046 * Bytestream, add instead [][google.bytestream.RestByteStream] as an API to |
| 3892 * configuration. | 4047 * your configuration for Bytestream methods. |
| 3893 */ | 4048 */ |
| 3894 class MediaUpload { | 4049 class MediaUpload { |
| 3895 /** Whether upload is enabled. */ | 4050 /** Whether upload is enabled. */ |
| 3896 core.bool enabled; | 4051 core.bool enabled; |
| 4052 /** |
| 4053 * DO NOT USE THIS FIELD UNTIL THIS WARNING IS REMOVED. |
| 4054 * |
| 4055 * Specify name of the upload service if one is used for upload. |
| 4056 */ |
| 4057 core.String uploadService; |
| 3897 | 4058 |
| 3898 MediaUpload(); | 4059 MediaUpload(); |
| 3899 | 4060 |
| 3900 MediaUpload.fromJson(core.Map _json) { | 4061 MediaUpload.fromJson(core.Map _json) { |
| 3901 if (_json.containsKey("enabled")) { | 4062 if (_json.containsKey("enabled")) { |
| 3902 enabled = _json["enabled"]; | 4063 enabled = _json["enabled"]; |
| 3903 } | 4064 } |
| 4065 if (_json.containsKey("uploadService")) { |
| 4066 uploadService = _json["uploadService"]; |
| 4067 } |
| 3904 } | 4068 } |
| 3905 | 4069 |
| 3906 core.Map toJson() { | 4070 core.Map toJson() { |
| 3907 var _json = new core.Map(); | 4071 var _json = new core.Map(); |
| 3908 if (enabled != null) { | 4072 if (enabled != null) { |
| 3909 _json["enabled"] = enabled; | 4073 _json["enabled"] = enabled; |
| 3910 } | 4074 } |
| 4075 if (uploadService != null) { |
| 4076 _json["uploadService"] = uploadService; |
| 4077 } |
| 3911 return _json; | 4078 return _json; |
| 3912 } | 4079 } |
| 3913 } | 4080 } |
| 3914 | 4081 |
| 3915 /** Method represents a method of an api. */ | 4082 /** Method represents a method of an api. */ |
| 3916 class Method { | 4083 class Method { |
| 3917 /** The simple name of this method. */ | 4084 /** The simple name of this method. */ |
| 3918 core.String name; | 4085 core.String name; |
| 3919 /** Any metadata attached to the method. */ | 4086 /** Any metadata attached to the method. */ |
| 3920 core.List<Option> options; | 4087 core.List<Option> options; |
| (...skipping 1262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5183 /** | 5350 /** |
| 5184 * A list of all enum types included in this API service. Enums | 5351 * A list of all enum types included in this API service. Enums |
| 5185 * referenced directly or indirectly by the `apis` are automatically | 5352 * referenced directly or indirectly by the `apis` are automatically |
| 5186 * included. Enums which are not referenced but shall be included | 5353 * included. Enums which are not referenced but shall be included |
| 5187 * should be listed here by name. Example: | 5354 * should be listed here by name. Example: |
| 5188 * | 5355 * |
| 5189 * enums: | 5356 * enums: |
| 5190 * - name: google.someapi.v1.SomeEnum | 5357 * - name: google.someapi.v1.SomeEnum |
| 5191 */ | 5358 */ |
| 5192 core.List<Enum> enums; | 5359 core.List<Enum> enums; |
| 5360 /** Experimental configuration. */ |
| 5361 Experimental experimental; |
| 5193 /** HTTP configuration. */ | 5362 /** HTTP configuration. */ |
| 5194 Http http; | 5363 Http http; |
| 5195 /** | 5364 /** |
| 5196 * A unique ID for a specific instance of this message, typically assigned | 5365 * A unique ID for a specific instance of this message, typically assigned |
| 5197 * by the client for tracking purpose. If empty, the server may choose to | 5366 * by the client for tracking purpose. If empty, the server may choose to |
| 5198 * generate one instead. | 5367 * generate one instead. |
| 5199 */ | 5368 */ |
| 5200 core.String id; | 5369 core.String id; |
| 5201 /** Logging configuration. */ | 5370 /** Logging configuration. */ |
| 5202 Logging logging; | 5371 Logging logging; |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5276 } | 5445 } |
| 5277 if (_json.containsKey("documentation")) { | 5446 if (_json.containsKey("documentation")) { |
| 5278 documentation = new Documentation.fromJson(_json["documentation"]); | 5447 documentation = new Documentation.fromJson(_json["documentation"]); |
| 5279 } | 5448 } |
| 5280 if (_json.containsKey("endpoints")) { | 5449 if (_json.containsKey("endpoints")) { |
| 5281 endpoints = _json["endpoints"].map((value) => new Endpoint.fromJson(value)
).toList(); | 5450 endpoints = _json["endpoints"].map((value) => new Endpoint.fromJson(value)
).toList(); |
| 5282 } | 5451 } |
| 5283 if (_json.containsKey("enums")) { | 5452 if (_json.containsKey("enums")) { |
| 5284 enums = _json["enums"].map((value) => new Enum.fromJson(value)).toList(); | 5453 enums = _json["enums"].map((value) => new Enum.fromJson(value)).toList(); |
| 5285 } | 5454 } |
| 5455 if (_json.containsKey("experimental")) { |
| 5456 experimental = new Experimental.fromJson(_json["experimental"]); |
| 5457 } |
| 5286 if (_json.containsKey("http")) { | 5458 if (_json.containsKey("http")) { |
| 5287 http = new Http.fromJson(_json["http"]); | 5459 http = new Http.fromJson(_json["http"]); |
| 5288 } | 5460 } |
| 5289 if (_json.containsKey("id")) { | 5461 if (_json.containsKey("id")) { |
| 5290 id = _json["id"]; | 5462 id = _json["id"]; |
| 5291 } | 5463 } |
| 5292 if (_json.containsKey("logging")) { | 5464 if (_json.containsKey("logging")) { |
| 5293 logging = new Logging.fromJson(_json["logging"]); | 5465 logging = new Logging.fromJson(_json["logging"]); |
| 5294 } | 5466 } |
| 5295 if (_json.containsKey("logs")) { | 5467 if (_json.containsKey("logs")) { |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5355 } | 5527 } |
| 5356 if (documentation != null) { | 5528 if (documentation != null) { |
| 5357 _json["documentation"] = (documentation).toJson(); | 5529 _json["documentation"] = (documentation).toJson(); |
| 5358 } | 5530 } |
| 5359 if (endpoints != null) { | 5531 if (endpoints != null) { |
| 5360 _json["endpoints"] = endpoints.map((value) => (value).toJson()).toList(); | 5532 _json["endpoints"] = endpoints.map((value) => (value).toJson()).toList(); |
| 5361 } | 5533 } |
| 5362 if (enums != null) { | 5534 if (enums != null) { |
| 5363 _json["enums"] = enums.map((value) => (value).toJson()).toList(); | 5535 _json["enums"] = enums.map((value) => (value).toJson()).toList(); |
| 5364 } | 5536 } |
| 5537 if (experimental != null) { |
| 5538 _json["experimental"] = (experimental).toJson(); |
| 5539 } |
| 5365 if (http != null) { | 5540 if (http != null) { |
| 5366 _json["http"] = (http).toJson(); | 5541 _json["http"] = (http).toJson(); |
| 5367 } | 5542 } |
| 5368 if (id != null) { | 5543 if (id != null) { |
| 5369 _json["id"] = id; | 5544 _json["id"] = id; |
| 5370 } | 5545 } |
| 5371 if (logging != null) { | 5546 if (logging != null) { |
| 5372 _json["logging"] = (logging).toJson(); | 5547 _json["logging"] = (logging).toJson(); |
| 5373 } | 5548 } |
| 5374 if (logs != null) { | 5549 if (logs != null) { |
| (...skipping 863 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6238 var _json = new core.Map(); | 6413 var _json = new core.Map(); |
| 6239 if (restriction != null) { | 6414 if (restriction != null) { |
| 6240 _json["restriction"] = restriction; | 6415 _json["restriction"] = restriction; |
| 6241 } | 6416 } |
| 6242 if (selector != null) { | 6417 if (selector != null) { |
| 6243 _json["selector"] = selector; | 6418 _json["selector"] = selector; |
| 6244 } | 6419 } |
| 6245 return _json; | 6420 return _json; |
| 6246 } | 6421 } |
| 6247 } | 6422 } |
| OLD | NEW |