Class: Google::Cloud::ApigeeRegistry::V1::Registry::Rest::Client
- Inherits:
-
Object
- Object
- Google::Cloud::ApigeeRegistry::V1::Registry::Rest::Client
- Includes:
- Paths
- Defined in:
- lib/google/cloud/apigee_registry/v1/registry/rest/client.rb
Overview
REST client for the Registry service.
The Registry service allows teams to manage descriptions of APIs.
Defined Under Namespace
Classes: Configuration
Instance Attribute Summary collapse
-
#iam_policy_client ⇒ Google::Iam::V1::IAMPolicy::Rest::Client
readonly
Get the associated client for mix-in of the IAMPolicy.
-
#location_client ⇒ Google::Cloud::Location::Locations::Rest::Client
readonly
Get the associated client for mix-in of the Locations.
Class Method Summary collapse
-
.configure {|config| ... } ⇒ Client::Configuration
Configure the Registry Client class.
Instance Method Summary collapse
-
#configure {|config| ... } ⇒ Client::Configuration
Configure the Registry Client instance.
-
#create_api(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api
Creates a specified API.
-
#create_api_deployment(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Creates a specified deployment.
-
#create_api_spec(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Creates a specified spec.
-
#create_api_version(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion
Creates a specified version.
-
#create_artifact(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact
Creates a specified artifact.
-
#delete_api(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Removes a specified API and all of the resources that it owns.
-
#delete_api_deployment(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Removes a specified deployment, all revisions, and all child resources (e.g., artifacts).
-
#delete_api_deployment_revision(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Deletes a revision of a deployment.
-
#delete_api_spec(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Removes a specified spec, all revisions, and all child resources (e.g., artifacts).
-
#delete_api_spec_revision(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Deletes a revision of a spec.
-
#delete_api_version(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Removes a specified version and all of the resources that it owns.
-
#delete_artifact(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Removes a specified artifact.
-
#get_api(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api
Returns a specified API.
-
#get_api_deployment(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Returns a specified deployment.
-
#get_api_spec(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Returns a specified spec.
-
#get_api_spec_contents(request, options = nil) {|result, operation| ... } ⇒ ::Google::Api::HttpBody
Returns the contents of a specified spec.
-
#get_api_version(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion
Returns a specified version.
-
#get_artifact(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact
Returns a specified artifact.
-
#get_artifact_contents(request, options = nil) {|result, operation| ... } ⇒ ::Google::Api::HttpBody
Returns the contents of a specified artifact.
-
#initialize {|config| ... } ⇒ Client
constructor
Create a new Registry REST client object.
-
#list_api_deployment_revisions(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiDeployment>
Lists all revisions of a deployment.
-
#list_api_deployments(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiDeployment>
Returns matching deployments.
-
#list_api_spec_revisions(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiSpec>
Lists all revisions of a spec.
-
#list_api_specs(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiSpec>
Returns matching specs.
-
#list_api_versions(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiVersion>
Returns matching versions.
-
#list_apis(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::Api>
Returns matching APIs.
-
#list_artifacts(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::Artifact>
Returns matching artifacts.
-
#replace_artifact(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact
Used to replace a specified artifact.
-
#rollback_api_deployment(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Sets the current revision to a specified prior revision.
-
#rollback_api_spec(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Sets the current revision to a specified prior revision.
-
#tag_api_deployment_revision(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Adds a tag to a specified revision of a deployment.
-
#tag_api_spec_revision(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Adds a tag to a specified revision of a spec.
-
#universe_domain ⇒ String
The effective universe domain.
-
#update_api(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api
Used to modify a specified API.
-
#update_api_deployment(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Used to modify a specified deployment.
-
#update_api_spec(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Used to modify a specified spec.
-
#update_api_version(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion
Used to modify a specified version.
Methods included from Paths
#api_deployment_path, #api_path, #api_spec_path, #api_version_path, #artifact_path, #location_path
Constructor Details
#initialize {|config| ... } ⇒ Client
Create a new Registry REST client object.
297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 297 def initialize # Create the configuration object @config = Configuration.new Client.configure # Yield the configuration if needed yield @config if block_given? # Create credentials credentials = @config.credentials # Use self-signed JWT if the endpoint is unchanged from default, # but only if the default endpoint does not have a region prefix. enable_self_signed_jwt = @config.endpoint.nil? || (@config.endpoint == Configuration::DEFAULT_ENDPOINT && !@config.endpoint.split(".").first.include?("-")) credentials ||= Credentials.default scope: @config.scope, enable_self_signed_jwt: enable_self_signed_jwt if credentials.is_a?(::String) || credentials.is_a?(::Hash) credentials = Credentials.new credentials, scope: @config.scope end @quota_project_id = @config.quota_project @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id @registry_stub = ::Google::Cloud::ApigeeRegistry::V1::Registry::Rest::ServiceStub.new( endpoint: @config.endpoint, endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, universe_domain: @config.universe_domain, credentials: credentials ) @location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config| config.credentials = credentials config.quota_project = @quota_project_id config.endpoint = @registry_stub.endpoint config.universe_domain = @registry_stub.universe_domain config.bindings_override = @config.bindings_override end @iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config| config.credentials = credentials config.quota_project = @quota_project_id config.endpoint = @registry_stub.endpoint config.universe_domain = @registry_stub.universe_domain config.bindings_override = @config.bindings_override end end |
Instance Attribute Details
#iam_policy_client ⇒ Google::Iam::V1::IAMPolicy::Rest::Client (readonly)
Get the associated client for mix-in of the IAMPolicy.
356 357 358 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 356 def iam_policy_client @iam_policy_client end |
#location_client ⇒ Google::Cloud::Location::Locations::Rest::Client (readonly)
Get the associated client for mix-in of the Locations.
349 350 351 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 349 def location_client @location_client end |
Class Method Details
.configure {|config| ... } ⇒ Client::Configuration
Configure the Registry Client class.
See Configuration for a description of the configuration fields.
66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 66 def self.configure @configure ||= begin namespace = ["Google", "Cloud", "ApigeeRegistry", "V1"] parent_config = while namespace.any? parent_name = namespace.join "::" parent_const = const_get parent_name break parent_const.configure if parent_const.respond_to? :configure namespace.pop end default_config = Client::Configuration.new parent_config default_config.rpcs.list_apis.timeout = 60.0 default_config.rpcs.list_apis.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.get_api.timeout = 60.0 default_config.rpcs.get_api.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.create_api.timeout = 60.0 default_config.rpcs.create_api.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.update_api.timeout = 60.0 default_config.rpcs.update_api.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.delete_api.timeout = 60.0 default_config.rpcs.delete_api.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.list_api_versions.timeout = 60.0 default_config.rpcs.list_api_versions.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.get_api_version.timeout = 60.0 default_config.rpcs.get_api_version.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.create_api_version.timeout = 60.0 default_config.rpcs.create_api_version.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.update_api_version.timeout = 60.0 default_config.rpcs.update_api_version.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.delete_api_version.timeout = 60.0 default_config.rpcs.delete_api_version.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.list_api_specs.timeout = 60.0 default_config.rpcs.list_api_specs.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.get_api_spec.timeout = 60.0 default_config.rpcs.get_api_spec.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.get_api_spec_contents.timeout = 60.0 default_config.rpcs.get_api_spec_contents.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.create_api_spec.timeout = 60.0 default_config.rpcs.create_api_spec.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.update_api_spec.timeout = 60.0 default_config.rpcs.update_api_spec.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.delete_api_spec.timeout = 60.0 default_config.rpcs.delete_api_spec.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.tag_api_spec_revision.timeout = 60.0 default_config.rpcs.tag_api_spec_revision.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.list_api_spec_revisions.timeout = 60.0 default_config.rpcs.list_api_spec_revisions.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.rollback_api_spec.timeout = 60.0 default_config.rpcs.delete_api_spec_revision.timeout = 60.0 default_config.rpcs.delete_api_spec_revision.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.list_api_deployments.timeout = 60.0 default_config.rpcs.list_api_deployments.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.get_api_deployment.timeout = 60.0 default_config.rpcs.get_api_deployment.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.create_api_deployment.timeout = 60.0 default_config.rpcs.create_api_deployment.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.update_api_deployment.timeout = 60.0 default_config.rpcs.update_api_deployment.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.delete_api_deployment.timeout = 60.0 default_config.rpcs.delete_api_deployment.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.tag_api_deployment_revision.timeout = 60.0 default_config.rpcs.tag_api_deployment_revision.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.list_api_deployment_revisions.timeout = 60.0 default_config.rpcs.list_api_deployment_revisions.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.rollback_api_deployment.timeout = 60.0 default_config.rpcs.delete_api_deployment_revision.timeout = 60.0 default_config.rpcs.delete_api_deployment_revision.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.list_artifacts.timeout = 60.0 default_config.rpcs.list_artifacts.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.get_artifact.timeout = 60.0 default_config.rpcs.get_artifact.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.get_artifact_contents.timeout = 60.0 default_config.rpcs.get_artifact_contents.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.create_artifact.timeout = 60.0 default_config.rpcs.create_artifact.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.replace_artifact.timeout = 60.0 default_config.rpcs.replace_artifact.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config.rpcs.delete_artifact.timeout = 60.0 default_config.rpcs.delete_artifact.retry_policy = { initial_delay: 0.2, max_delay: 60.0, multiplier: 1.3, retry_codes: [10, 1, 4, 14] } default_config end yield @configure if block_given? @configure end |
Instance Method Details
#configure {|config| ... } ⇒ Client::Configuration
Configure the Registry Client instance.
The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on configure.
See Configuration for a description of the configuration fields.
267 268 269 270 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 267 def configure yield @config if block_given? @config end |
#create_api(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api #create_api(parent: nil, api: nil, api_id: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api
Creates a specified API.
593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 593 def create_api request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::CreateApiRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_api..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_api.timeout, metadata: , retry_policy: @config.rpcs.create_api.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.create_api request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_api_deployment(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment #create_api_deployment(parent: nil, api_deployment: nil, api_deployment_id: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Creates a specified deployment.
2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2345 def create_api_deployment request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::CreateApiDeploymentRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_api_deployment..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_api_deployment.timeout, metadata: , retry_policy: @config.rpcs.create_api_deployment.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.create_api_deployment request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_api_spec(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec #create_api_spec(parent: nil, api_spec: nil, api_spec_id: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Creates a specified spec.
1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1562 def create_api_spec request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::CreateApiSpecRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_api_spec..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_api_spec.timeout, metadata: , retry_policy: @config.rpcs.create_api_spec.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.create_api_spec request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_api_version(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion #create_api_version(parent: nil, api_version: nil, api_version_id: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion
Creates a specified version.
1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1036 def create_api_version request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::CreateApiVersionRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_api_version..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_api_version.timeout, metadata: , retry_policy: @config.rpcs.create_api_version.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.create_api_version request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_artifact(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact #create_artifact(parent: nil, artifact: nil, artifact_id: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact
Creates a specified artifact.
3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 3212 def create_artifact request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::CreateArtifactRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_artifact..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_artifact.timeout, metadata: , retry_policy: @config.rpcs.create_artifact.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.create_artifact request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_api(request, options = nil) ⇒ ::Google::Protobuf::Empty #delete_api(name: nil, force: nil) ⇒ ::Google::Protobuf::Empty
Removes a specified API and all of the resources that it owns.
767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 767 def delete_api request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::DeleteApiRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_api..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_api.timeout, metadata: , retry_policy: @config.rpcs.delete_api.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.delete_api request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_api_deployment(request, options = nil) ⇒ ::Google::Protobuf::Empty #delete_api_deployment(name: nil, force: nil) ⇒ ::Google::Protobuf::Empty
Removes a specified deployment, all revisions, and all child resources (e.g., artifacts).
2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2519 def delete_api_deployment request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::DeleteApiDeploymentRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_api_deployment..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_api_deployment.timeout, metadata: , retry_policy: @config.rpcs.delete_api_deployment.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.delete_api_deployment request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_api_deployment_revision(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment #delete_api_deployment_revision(name: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Deletes a revision of a deployment.
2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2860 def delete_api_deployment_revision request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::DeleteApiDeploymentRevisionRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_api_deployment_revision..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_api_deployment_revision.timeout, metadata: , retry_policy: @config.rpcs.delete_api_deployment_revision.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.delete_api_deployment_revision request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_api_spec(request, options = nil) ⇒ ::Google::Protobuf::Empty #delete_api_spec(name: nil, force: nil) ⇒ ::Google::Protobuf::Empty
Removes a specified spec, all revisions, and all child resources (e.g., artifacts).
1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1736 def delete_api_spec request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::DeleteApiSpecRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_api_spec..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_api_spec.timeout, metadata: , retry_policy: @config.rpcs.delete_api_spec.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.delete_api_spec request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_api_spec_revision(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec #delete_api_spec_revision(name: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Deletes a revision of a spec.
2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2076 def delete_api_spec_revision request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::DeleteApiSpecRevisionRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_api_spec_revision..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_api_spec_revision.timeout, metadata: , retry_policy: @config.rpcs.delete_api_spec_revision.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.delete_api_spec_revision request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_api_version(request, options = nil) ⇒ ::Google::Protobuf::Empty #delete_api_version(name: nil, force: nil) ⇒ ::Google::Protobuf::Empty
Removes a specified version and all of the resources that it owns.
1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1210 def delete_api_version request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::DeleteApiVersionRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_api_version..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_api_version.timeout, metadata: , retry_policy: @config.rpcs.delete_api_version.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.delete_api_version request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_artifact(request, options = nil) ⇒ ::Google::Protobuf::Empty #delete_artifact(name: nil) ⇒ ::Google::Protobuf::Empty
Removes a specified artifact.
3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 3374 def delete_artifact request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::DeleteArtifactRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_artifact..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_artifact.timeout, metadata: , retry_policy: @config.rpcs.delete_artifact.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.delete_artifact request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_api(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api #get_api(name: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api
Returns a specified API.
503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 503 def get_api request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::GetApiRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_api..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_api.timeout, metadata: , retry_policy: @config.rpcs.get_api.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.get_api request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_api_deployment(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment #get_api_deployment(name: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Returns a specified deployment.
2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2255 def get_api_deployment request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::GetApiDeploymentRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_api_deployment..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_api_deployment.timeout, metadata: , retry_policy: @config.rpcs.get_api_deployment.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.get_api_deployment request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_api_spec(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec #get_api_spec(name: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Returns a specified spec.
1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1389 def get_api_spec request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::GetApiSpecRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_api_spec..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_api_spec.timeout, metadata: , retry_policy: @config.rpcs.get_api_spec.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.get_api_spec request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_api_spec_contents(request, options = nil) ⇒ ::Google::Api::HttpBody #get_api_spec_contents(name: nil) ⇒ ::Google::Api::HttpBody
Returns the contents of a specified spec. If specs are stored with GZip compression, the default behavior is to return the spec uncompressed (the mime_type response field indicates the exact format returned).
1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1472 def get_api_spec_contents request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::GetApiSpecContentsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_api_spec_contents..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_api_spec_contents.timeout, metadata: , retry_policy: @config.rpcs.get_api_spec_contents.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.get_api_spec_contents request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_api_version(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion #get_api_version(name: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion
Returns a specified version.
946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 946 def get_api_version request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::GetApiVersionRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_api_version..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_api_version.timeout, metadata: , retry_policy: @config.rpcs.get_api_version.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.get_api_version request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_artifact(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact #get_artifact(name: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact
Returns a specified artifact.
3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 3039 def get_artifact request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::GetArtifactRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_artifact..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_artifact.timeout, metadata: , retry_policy: @config.rpcs.get_artifact.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.get_artifact request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_artifact_contents(request, options = nil) ⇒ ::Google::Api::HttpBody #get_artifact_contents(name: nil) ⇒ ::Google::Api::HttpBody
Returns the contents of a specified artifact. If artifacts are stored with GZip compression, the default behavior is to return the artifact uncompressed (the mime_type response field indicates the exact format returned).
3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 3122 def get_artifact_contents request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::GetArtifactContentsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_artifact_contents..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_artifact_contents.timeout, metadata: , retry_policy: @config.rpcs.get_artifact_contents.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.get_artifact_contents request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_api_deployment_revisions(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiDeployment> #list_api_deployment_revisions(name: nil, page_size: nil, page_token: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiDeployment>
Lists all revisions of a deployment. Revisions are returned in descending order of revision creation time.
2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2691 def list_api_deployment_revisions request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::ListApiDeploymentRevisionsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_api_deployment_revisions..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_api_deployment_revisions.timeout, metadata: , retry_policy: @config.rpcs.list_api_deployment_revisions.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.list_api_deployment_revisions request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_deployment_revisions, "api_deployments", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_api_deployments(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiDeployment> #list_api_deployments(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiDeployment>
Returns matching deployments.
2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2174 def list_api_deployments request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::ListApiDeploymentsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_api_deployments..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_api_deployments.timeout, metadata: , retry_policy: @config.rpcs.list_api_deployments.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.list_api_deployments request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_deployments, "api_deployments", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_api_spec_revisions(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiSpec> #list_api_spec_revisions(name: nil, page_size: nil, page_token: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiSpec>
Lists all revisions of a spec. Revisions are returned in descending order of revision creation time.
1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1907 def list_api_spec_revisions request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::ListApiSpecRevisionsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_api_spec_revisions..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_api_spec_revisions.timeout, metadata: , retry_policy: @config.rpcs.list_api_spec_revisions.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.list_api_spec_revisions request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_spec_revisions, "api_specs", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_api_specs(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiSpec> #list_api_specs(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiSpec>
Returns matching specs.
1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1308 def list_api_specs request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::ListApiSpecsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_api_specs..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_api_specs.timeout, metadata: , retry_policy: @config.rpcs.list_api_specs.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.list_api_specs request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_specs, "api_specs", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_api_versions(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiVersion> #list_api_versions(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::ApiVersion>
Returns matching versions.
865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 865 def list_api_versions request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::ListApiVersionsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_api_versions..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_api_versions.timeout, metadata: , retry_policy: @config.rpcs.list_api_versions.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.list_api_versions request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_api_versions, "api_versions", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_apis(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::Api> #list_apis(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::Api>
Returns matching APIs.
422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 422 def list_apis request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::ListApisRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_apis..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_apis.timeout, metadata: , retry_policy: @config.rpcs.list_apis.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.list_apis request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_apis, "apis", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_artifacts(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::Artifact> #list_artifacts(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::ApigeeRegistry::V1::Artifact>
Returns matching artifacts.
2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2958 def list_artifacts request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::ListArtifactsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_artifacts..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_artifacts.timeout, metadata: , retry_policy: @config.rpcs.list_artifacts.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.list_artifacts request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @registry_stub, :list_artifacts, "artifacts", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#replace_artifact(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact #replace_artifact(artifact: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Artifact
Used to replace a specified artifact.
3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 3294 def replace_artifact request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::ReplaceArtifactRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.replace_artifact..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.replace_artifact.timeout, metadata: , retry_policy: @config.rpcs.replace_artifact.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.replace_artifact request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#rollback_api_deployment(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment #rollback_api_deployment(name: nil, revision_id: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Sets the current revision to a specified prior revision. Note that this creates a new revision with a new revision ID.
2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2777 def rollback_api_deployment request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::RollbackApiDeploymentRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.rollback_api_deployment..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.rollback_api_deployment.timeout, metadata: , retry_policy: @config.rpcs.rollback_api_deployment.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.rollback_api_deployment request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#rollback_api_spec(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec #rollback_api_spec(name: nil, revision_id: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Sets the current revision to a specified prior revision. Note that this creates a new revision with a new revision ID.
1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1993 def rollback_api_spec request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::RollbackApiSpecRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.rollback_api_spec..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.rollback_api_spec.timeout, metadata: , retry_policy: @config.rpcs.rollback_api_spec.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.rollback_api_spec request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#tag_api_deployment_revision(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment #tag_api_deployment_revision(name: nil, tag: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Adds a tag to a specified revision of a deployment.
2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2602 def tag_api_deployment_revision request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::TagApiDeploymentRevisionRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.tag_api_deployment_revision..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.tag_api_deployment_revision.timeout, metadata: , retry_policy: @config.rpcs.tag_api_deployment_revision.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.tag_api_deployment_revision request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#tag_api_spec_revision(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec #tag_api_spec_revision(name: nil, tag: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Adds a tag to a specified revision of a spec.
1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1818 def tag_api_spec_revision request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::TagApiSpecRevisionRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.tag_api_spec_revision..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.tag_api_spec_revision.timeout, metadata: , retry_policy: @config.rpcs.tag_api_spec_revision.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.tag_api_spec_revision request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#universe_domain ⇒ String
The effective universe domain
277 278 279 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 277 def universe_domain @registry_stub.universe_domain end |
#update_api(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api #update_api(api: nil, update_mask: nil, allow_missing: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::Api
Used to modify a specified API.
683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 683 def update_api request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::UpdateApiRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.update_api..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.update_api.timeout, metadata: , retry_policy: @config.rpcs.update_api.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.update_api request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#update_api_deployment(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment #update_api_deployment(api_deployment: nil, update_mask: nil, allow_missing: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiDeployment
Used to modify a specified deployment.
2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 2435 def update_api_deployment request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::UpdateApiDeploymentRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.update_api_deployment..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.update_api_deployment.timeout, metadata: , retry_policy: @config.rpcs.update_api_deployment.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.update_api_deployment request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#update_api_spec(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec #update_api_spec(api_spec: nil, update_mask: nil, allow_missing: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiSpec
Used to modify a specified spec.
1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1652 def update_api_spec request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::UpdateApiSpecRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.update_api_spec..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.update_api_spec.timeout, metadata: , retry_policy: @config.rpcs.update_api_spec.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.update_api_spec request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#update_api_version(request, options = nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion #update_api_version(api_version: nil, update_mask: nil, allow_missing: nil) ⇒ ::Google::Cloud::ApigeeRegistry::V1::ApiVersion
Used to modify a specified version.
1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 |
# File 'lib/google/cloud/apigee_registry/v1/registry/rest/client.rb', line 1126 def update_api_version request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::ApigeeRegistry::V1::UpdateApiVersionRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.update_api_version..to_h # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::ApigeeRegistry::V1::VERSION, transports_version_send: [:rest] [:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.update_api_version.timeout, metadata: , retry_policy: @config.rpcs.update_api_version.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @registry_stub.update_api_version request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |